From owner-freebsd-net@FreeBSD.ORG Tue Sep 21 18:19:10 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6D77216A4CE; Tue, 21 Sep 2004 18:19:10 +0000 (GMT) Received: from odin.ac.hmc.edu (Odin.AC.HMC.Edu [134.173.32.75]) by mx1.FreeBSD.org (Postfix) with ESMTP id 41C9F43D1D; Tue, 21 Sep 2004 18:19:10 +0000 (GMT) (envelope-from brdavis@odin.ac.hmc.edu) Received: from odin.ac.hmc.edu (localhost.localdomain [127.0.0.1]) by odin.ac.hmc.edu (8.13.0/8.13.0) with ESMTP id i8LILQC5009301; Tue, 21 Sep 2004 11:21:26 -0700 Received: (from brdavis@localhost) by odin.ac.hmc.edu (8.13.0/8.13.0/Submit) id i8LILQsb009300; Tue, 21 Sep 2004 11:21:26 -0700 Date: Tue, 21 Sep 2004 11:21:25 -0700 From: Brooks Davis To: Thomas Quinot Message-ID: <20040921182125.GA7566@odin.ac.hmc.edu> References: <20040921123016.GA41677@melusine.cuivre.fr.eu.org> <20040921180746.GB49259@melusine.cuivre.fr.eu.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="0OAP2g/MAC+5xKAE" Content-Disposition: inline In-Reply-To: <20040921180746.GB49259@melusine.cuivre.fr.eu.org> User-Agent: Mutt/1.4.1i X-Virus-Scanned: by amavisd-new X-Spam-Status: No, hits=0.0 required=8.0 tests=none autolearn=no version=2.63 X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on odin.ac.hmc.edu cc: freebsd-net@freebsd.org cc: Hajimu UMEMOTO Subject: Re: freeaddrinfo(NULL) X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Sep 2004 18:19:10 -0000 --0OAP2g/MAC+5xKAE Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Sep 21, 2004 at 08:07:46PM +0200, Thomas Quinot wrote: > * Hajimu UMEMOTO, 2004-09-21 : >=20 > > Because, the behavior of freeaddrinfo (NULL) is undefined in RFC 2553 > > nor RFC 3493. Having such an assumption is a potentially bug and > > lose portability. >=20 > That a construct has no defined meaning does not imply that we must make > every effort to break applications that (erroneously) make use of it. > Would there be any significant drawback for conforming applications > if we made our best to deploy a safety net againt buggy user programs > by not segfaulting in this case? >=20 > There are many situations where the system already detects an invalid > pointer and reports it gracefully as an error rather than triggering a > fatal signal. If it wouldn't be too evil, making freeaddrinfo die when malloc's A flag was set and succeed otherwise might be a reasionable compromise. -- Brooks --=20 Any statement of the form "X is the one, true Y" is FALSE. PGP fingerprint 655D 519C 26A7 82E7 2529 9BF0 5D8E 8BE9 F238 1AD4 --0OAP2g/MAC+5xKAE Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (GNU/Linux) iD8DBQFBUHElXY6L6fI4GtQRAn62AKCnB1ywmRnF1+Cbg9tlM2+AFJPo8QCfWWNi 2ZXUSrXjbKkN4MAWdQ+kb6s= =hisd -----END PGP SIGNATURE----- --0OAP2g/MAC+5xKAE--