From nobody Fri Feb 10 04:14:26 2023 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4PCgNf4g70z3nRNN; Fri, 10 Feb 2023 04:14:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4PCgNf41Nqz49CC; Fri, 10 Feb 2023 04:14:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1676002466; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9NGRr4uxMQZGowOjLenqd27lgfmGY7qZi1Wwl/wUgBU=; b=B1qiT6zU31hhPj1e9G9vq6sHVwMKO9mkPlRhvUW/DZYh/F2KILSKweys8exc1TlmtnGRmm FOerlM+OhBpQfoX3rkRXHTof6OcSGtSROhaLfe2h8H7ORs8SgCO305Ru+4J7ca4QXo9HTe 7EpwkG76v9m+X3A2uh/1zkWT5K/AD1ja0JWb2vmQ0ek+2KrwgQDC68YKji/vBlp3T76FeQ Mt3/nQmbvHhOX0ixGR80naWFMVmihMnFbmV0eZGoPGuHaF1QYDUlk+0EamzYyOPjTLgAhQ RpBTVWfrM6UQDjKfjvUwak5mQWGxqu2ozw7mrb6hGHiG4dm92iE3a9v0j3vfsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1676002466; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=9NGRr4uxMQZGowOjLenqd27lgfmGY7qZi1Wwl/wUgBU=; b=UrSXbJ3Xge//srUBBRXYYE6dnSkT8cvjcN7kUNdZaozxvSxQcnlk8m6wBT3DDXn8lJFf8H aX5HK5894q8NmZEwsdmUe36/roaBSCAXylrKtQIWx0UotST/EBO88vZmiSwe5pa5NjwqvR 2bxQ4CK/yl+dc98QF9vpb5TnjZdUrH/widJzmIckLjxgoCS+dG9pNwsFT85gc549Ihfj3I nBvUF1YATg9R33+hZqO21INml5+Eun7xHyJrzlBhsW+zeQzrCzWdC9ysOdvMTM/YAd/Prf 85s5I9eOyBOq7l4j5KniEJA97OzgQ1NdDE14vL7pD5fd0RMyLkwyxEW8jC0l7g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1676002466; a=rsa-sha256; cv=none; b=H2jPM13DsE0j8xubSjg1VzhTIzedk/xtQsih//91uGTuk6kMb/aAVuGNyAoaaT+0q+ruTl aMaibg2mFm1CTKkDaOtyXvtk5m4Z1iuVsQuGRvj8gMug5joKUZkAiHjd+S1iYPJik6PXga xlRyA2A4ctCWfKH2Q89mjJ/FOPkWtsiRx0vnwcnoMvQ7vSMHLfbs8JdQJWW193xTkNEgol 7ogEFj7jirjUBNgR5Qt1tHqDJ0lyQtw9GC3c7kEd30IxeO5RXDPD7601RVJIRCt9KgU72v afgWFcv/JhKWJ5WcaeE2weYtmR8XDR2NZpYIZ1EIUzll9QuEeX+/caCTLYEshw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4PCgNf352cz14J5; Fri, 10 Feb 2023 04:14:26 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 31A4EQFo045939; Fri, 10 Feb 2023 04:14:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 31A4EQSM045938; Fri, 10 Feb 2023 04:14:26 GMT (envelope-from git) Date: Fri, 10 Feb 2023 04:14:26 GMT Message-Id: <202302100414.31A4EQSM045938@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: f44df7959ae2 - main - libc: ssp: remove some GCC 4.2 remnants List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f44df7959ae251e64939a03b92989592d7d6ac31 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=f44df7959ae251e64939a03b92989592d7d6ac31 commit f44df7959ae251e64939a03b92989592d7d6ac31 Author: Kyle Evans AuthorDate: 2023-02-10 04:08:07 +0000 Commit: Kyle Evans CommitDate: 2023-02-10 04:11:54 +0000 libc: ssp: remove some GCC 4.2 remnants With GCC 4.2 out of the tree for a while now and no sign of it returning, we don't really need to support older versions that don't allow us to specify a ctor priority anymore. Noticed by: mjg --- lib/libc/secure/stack_protector.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/lib/libc/secure/stack_protector.c b/lib/libc/secure/stack_protector.c index 7ddd6338ec55..909debecf26e 100644 --- a/lib/libc/secure/stack_protector.c +++ b/lib/libc/secure/stack_protector.c @@ -47,23 +47,15 @@ __FBSDID("$FreeBSD$"); * they're either not usually statically linked or they simply don't do things * in constructors that would be adversely affected by their positioning with * respect to this initialization. - * - * This conditional should be removed when GCC 4.2 is removed. */ -#if __has_attribute(__constructor__) || __GNUC_PREREQ__(4, 3) -#define _GUARD_SETUP_CTOR_ATTR \ +static void __guard_setup(void) __attribute__((__constructor__ (200), __used__)); -#else -#define _GUARD_SETUP_CTOR_ATTR \ - __attribute__((__constructor__, __used__)); -#endif extern long __stack_chk_guard[8]; extern int __sysctl(const int *name, u_int namelen, void *oldp, size_t *oldlenp, void *newp, size_t newlen); long __stack_chk_guard[8] = {0, 0, 0, 0, 0, 0, 0, 0}; -static void __guard_setup(void) _GUARD_SETUP_CTOR_ATTR; static void __fail(const char *) __dead2; void __stack_chk_fail(void) __dead2; void __chk_fail(void) __dead2;