From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from quail.birch.relay.mailchannels.net (quail.birch.relay.mailchannels.net [23.83.209.151]) by sourceware.org (Postfix) with ESMTPS id C04FC3858D35 for ; Fri, 24 Mar 2023 15:23:04 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org C04FC3858D35 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=sourceware.org Authentication-Results: sourceware.org; spf=fail smtp.mailfrom=sourceware.org X-Sender-Id: dreamhost|x-authsender|siddhesh@gotplt.org Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 158DD5C2625; Fri, 24 Mar 2023 15:23:03 +0000 (UTC) Received: from pdx1-sub0-mail-a306.dreamhost.com (unknown [127.0.0.6]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 5DE1B5C265F; Fri, 24 Mar 2023 15:23:02 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1679671382; a=rsa-sha256; cv=none; b=Z/EbzSe2nx4UW2NrrjMav3NxdkxVU9IQ2u8adWhU6giYEB5jcZiI3rE4Ge6WIEENL41k2x INEJ/F6gzI4fLx+G/5GYgl3YWBaIRl8gLGQ2mB+LuwAFw2pln1D2qHXGBkUi6CMdJvsDgQ p4I8QD1JaMUxwGteGvO4gUCfcRZdliGIlOm7CAOCWzFbwFDTuV0+uvaAFJ11inrsTM814Z TnvB/xCPzjIE2sYfDx2+q/MaKBmdhSquuyM4QJKNkuSlgvUCKSaE/0We9mKINl9+0ccSpj dj+j0l/zV4+IWdoVIoBCxDn1ExKObqcj9ICawOQzuP0tX1kKGIrm3zQOuvFBbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1679671382; 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: in-reply-to:in-reply-to:references:references; bh=pKGtpEiuKRgEtD+3TxoH4yk3fUQ9YkcyTyDxB8C7HY0=; b=Oif2dfQCJWMh1YKC0cyfr5pp7Rb1BcYJU284H2QmSYFR8s7diO5yuHHCfgIssTAgU752g1 f/pAEP96Gx/OwpFpH2PQ6r0ObDafOlOXS/QatjrgF9GmB+uYzN9oPc99hljQDwbwwiyKlw 0W/qLA5ugUB75EjGM2A+nfZWvGdCr5WZlMUIHOoPl3R7tEyNIEGaYkZ137hNGIfXKM3IgK 4LyJNtlfN1qZggkmKFlXUd1Ev4E/k6gIedo6kzoFWj1MDdkKpqFT4gY2WrhYi3v2Wmx0sm 2PTD61HUBBdR+pFM2QCAou1q7A1Yha4VUlB3it0h/HXfBTc7fFj7MQs6w2K3EQ== ARC-Authentication-Results: i=1; rspamd-9576589d-fc46x; auth=pass smtp.auth=dreamhost smtp.mailfrom=siddhesh@sourceware.org X-Sender-Id: dreamhost|x-authsender|siddhesh@gotplt.org X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|siddhesh@gotplt.org X-MailChannels-Auth-Id: dreamhost X-Macabre-White: 1ed33745171a2fa5_1679671382604_778335480 X-MC-Loop-Signature: 1679671382604:2777414846 X-MC-Ingress-Time: 1679671382604 Received: from pdx1-sub0-mail-a306.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.103.24.127 (trex/6.7.2); Fri, 24 Mar 2023 15:23:02 +0000 Received: from [192.168.0.182] (bras-vprn-toroon4834w-lp130-09-174-91-45-153.dsl.bell.ca [174.91.45.153]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: siddhesh@gotplt.org) by pdx1-sub0-mail-a306.dreamhost.com (Postfix) with ESMTPSA id 4PjmDk0J3rzDW; Fri, 24 Mar 2023 08:23:01 -0700 (PDT) Message-ID: <261a3c2b-3008-ab78-47ac-2b0c700500b3@sourceware.org> Date: Fri, 24 Mar 2023 11:23:01 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.8.0 Subject: Re: [PATCH] manual: Document __wur usage under _FORTIFY_SOURCE To: Florian Weimer , Siddhesh Poyarekar via Libc-alpha References: <20230324144005.26782-1-siddhesh@sourceware.org> <877cv62na6.fsf@mid.deneb.enyo.de> Content-Language: en-US From: Siddhesh Poyarekar In-Reply-To: <877cv62na6.fsf@mid.deneb.enyo.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1172.7 required=5.0 tests=BAYES_00,GIT_PATCH_0,KAM_DMARC_NONE,KAM_DMARC_STATUS,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_SOFTFAIL,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2023-03-24 11:15, Florian Weimer wrote: >> diff --git a/manual/maint.texi b/manual/maint.texi >> index 76d4a1a147..ae651c2a4a 100644 >> --- a/manual/maint.texi >> +++ b/manual/maint.texi >> @@ -206,7 +206,10 @@ to the function call are safe, the call may be replaced by a call to its >> hardened variant that does additional safety checks at runtime. Some >> hardened variants need the size of the buffer to perform access >> validation and this is provided by the @code{__builtin_object_size} or >> -the @code{__builtin_dynamic_object_size} builtin functions. >> +the @code{__builtin_dynamic_object_size} builtin functions. The macro >> +also enables additional compile time diagnostics, such as unchecked >> +return values from some functions, to encourage developers to add error >> +checking for those functions. > > Maybe repeat _FORTIFY_SOURCE it's been a while since it's been > mentioned? Ack, will do. > Note that now that GCC supports [[nodiscard]] (with the standard way > to suppress it), we could apply that to functions even outside > _FORTIFY_SOURCE, I think. That's a separate matter, of course. Yes, I've wondered that too. I'll start a separate thread about that later. Thanks, Sid