From patchwork Tue Jul 11 20:42:40 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 21548 Received: (qmail 81027 invoked by alias); 11 Jul 2017 20:42:46 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 79241 invoked by uid 89); 11 Jul 2017 20:42:44 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-25.0 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, RCVD_IN_SORBS_SPAM, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-oi0-f51.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=EJiDMeNUfA7AJrmou5wF81XPy+5iAcF8bb0ouF4Qc04=; b=WNYcMPYWQ5p0PfAuWwM8pYwXLveKvpCCpUsAT2IbP+bpbbN/x4TbcsNLj+CPgxD796 KwBdVxogCKU1ApKTd5ziLkdHZWrkn44qDYBZdbELB23gz8RUHthuXOpCuU8qSdzrsvxt AXx/QFCjzh6DRBXsvrl9B5vAdp8vcJ7K14sPGe51sPBDOJpCcq/SKY3urKj3iQFXb6DV YkqBxyg0AKqYO3WG0Oyaxv4vCuzH2I/xedZCrEUIGwIzO76e6Ffamy43x/Mceu3O4Jec xqyXhNVKxQ+9jNHXz4Tjr6PkYXHxjWi4DhP6v+89l9BuyyPvuY2/c1ZwYaK6xc7H6II0 VbVg== X-Gm-Message-State: AIVw111R4ednmSbEz4d5lQx4x8aDicOaVnuMc0SHp+Z9BcFtuaa8+MX6 O9tgwqXWAM4PpBnzIElP4T0SC6ku2w== X-Received: by 10.202.53.215 with SMTP id c206mr1420159oia.164.1499805761499; Tue, 11 Jul 2017 13:42:41 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <87iniy90oq.fsf@mid.deneb.enyo.de> References: <20170710200054.GA11938@gmail.com> <87pod7cq9r.fsf@mid.deneb.enyo.de> <20170711132509.GA3054@gmail.com> <87r2xm930u.fsf@mid.deneb.enyo.de> <87iniy90oq.fsf@mid.deneb.enyo.de> From: "H.J. Lu" Date: Tue, 11 Jul 2017 13:42:40 -0700 Message-ID: Subject: Re: [PATCH] Avoid backtrace from __stack_chk_fail [BZ #12189] To: Florian Weimer Cc: GNU C Library On Tue, Jul 11, 2017 at 1:29 PM, Florian Weimer wrote: > * H. J. Lu: > >> On Tue, Jul 11, 2017 at 12:39 PM, Florian Weimer wrote: >>> * H. J. Lu: >>> >>>> +CFLAGS-tst-ssp-1.c = -fstack-protector >>> >>> This should be -fstack-protector-all, in case the the stack protector >>> heuristics do not instrument a thirty-byte array. >> >> Does GCC 4.9 support -fstack-protector-all? > > It's mentioned in > > > > so I assume it does. (-fstack-protector-strong is the recent > addition.) Here is the patch. From 1e306164cc0b673433969994aa6a74d5db99c9f2 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Tue, 11 Jul 2017 13:40:56 -0700 Subject: [PATCH] Compile tst-ssp-1.c with -fstack-protector-all Compile tst-ssp-1.c with -fstack-protector-all in case the the stack protector heuristics do not instrument a thirty-byte array. * debug/Makefile (CFLAGS-tst-ssp-1.c): Set to -fstack-protector-all. --- ChangeLog | 5 +++++ debug/Makefile | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 018e4f2..4140e80 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2017-07-11 H.J. Lu + + * debug/Makefile (CFLAGS-tst-ssp-1.c): Set to + -fstack-protector-all. + 2017-07-11 Gabriel F. T. Gomes * sysdeps/powerpc/powerpc64le/Makefile: Use $(all-object-suffixes) diff --git a/debug/Makefile b/debug/Makefile index c6d7872..ce5fa88 100644 --- a/debug/Makefile +++ b/debug/Makefile @@ -139,7 +139,7 @@ LDFLAGS-tst-backtrace4 = -rdynamic LDFLAGS-tst-backtrace5 = -rdynamic LDFLAGS-tst-backtrace6 = -rdynamic -CFLAGS-tst-ssp-1.c = -fstack-protector +CFLAGS-tst-ssp-1.c = -fstack-protector-all tests = backtrace-tst tst-longjmp_chk tst-chk1 tst-chk2 tst-chk3 \ tst-lfschk1 tst-lfschk2 tst-lfschk3 test-strcpy_chk test-stpcpy_chk \ -- 2.9.4