From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from xry111.site (xry111.site [IPv6:2001:470:683e::1]) by sourceware.org (Postfix) with ESMTPS id 0ED5A385B19A for ; Sun, 4 Dec 2022 05:59:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 0ED5A385B19A Authentication-Results: sourceware.org; dmarc=pass (p=reject dis=none) header.from=xry111.site Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=xry111.site DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=xry111.site; s=default; t=1670133590; bh=Es37w2HIg9reAuC0yxJHoQWCN5uKZ7oevIYfLE9Cbeg=; h=Subject:From:To:Cc:Date:In-Reply-To:References:From; b=aQsQF3GgIlGXq96u9j1J1tm3WeHwIVNwr5BFPEvchcN9DXlT3BZUgYShz7KKrdTNd eRHIyIki6bP2tcc36Edosmq1Xp32GRt2BPXfYGHjMgx+OkspcMsBOVpW4r9RvD6ul2 CyjzY9zBj69B2zpwPuz0LgvMBplRTOBtiBagOMDA= Received: from localhost.localdomain (xry111.site [IPv6:2001:470:683e::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-384) server-digest SHA384) (Client did not present a certificate) (Authenticated sender: xry111@xry111.site) by xry111.site (Postfix) with ESMTPSA id B29A965A8C; Sun, 4 Dec 2022 00:59:49 -0500 (EST) Message-ID: Subject: Re: bind(2): Missing [[gnu::nonnull]] From: Xi Ruoyao To: Andreas Schwab , Xi Ruoyao via Libc-alpha Cc: Alejandro Colomar Date: Sun, 04 Dec 2022 13:59:48 +0800 In-Reply-To: <87wn78cnpe.fsf@igel.home> References: <8292ef824696e0fbac4f4ed036aad43c0458b8a2.camel@xry111.site> <87wn78cnpe.fsf@igel.home> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.0 MIME-Version: 1.0 X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FROM_SUSPICIOUS_NTLD,LIKELY_SPAM_FROM,SPF_HELO_PASS,SPF_PASS,TXREP,T_PDS_OTHER_BAD_TLD autolearn=no 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 Sat, 2022-12-03 at 20:05 +0100, Andreas Schwab wrote: > > Currently the man page says: > >=20 > > EFAULT: addr points outside the user's accessible address space. > >=20 > > And bind(2) indeed sets errno to EFAULT and return -1 when NULL is > > passed as addr. >=20 > You can never depend on EFAULT for invalid addresses. Hmm, is this documented somewhere? --=20 Xi Ruoyao School of Aerospace Science and Technology, Xidian University