From owner-svn-src-all@FreeBSD.ORG Sat Dec 17 08:34:13 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1F7A7106564A; Sat, 17 Dec 2011 08:34:13 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id 739238FC0C; Sat, 17 Dec 2011 08:34:11 +0000 (UTC) Received: from alf.home (alf.kiev.zoral.com.ua [10.1.1.177]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id pBH8Xtvt013821 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 17 Dec 2011 10:33:55 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from alf.home (kostik@localhost [127.0.0.1]) by alf.home (8.14.5/8.14.5) with ESMTP id pBH8Xtex059673; Sat, 17 Dec 2011 10:33:55 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by alf.home (8.14.5/8.14.5/Submit) id pBH8Xt8a059672; Sat, 17 Dec 2011 10:33:55 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: alf.home: kostik set sender to kostikbel@gmail.com using -f Date: Sat, 17 Dec 2011 10:33:55 +0200 From: Kostik Belousov To: Dimitry Andric Message-ID: <20111217083355.GZ50300@deviant.kiev.zoral.com.ua> References: <201112170136.pBH1apEH036884@svn.freebsd.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="lpp+eiGMS9nGU1lc" Content-Disposition: inline In-Reply-To: <201112170136.pBH1apEH036884@svn.freebsd.org> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-3.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r228616 - head/usr.bin/tar X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2011 08:34:13 -0000 --lpp+eiGMS9nGU1lc Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Dec 17, 2011 at 01:36:51AM +0000, Dimitry Andric wrote: > Author: dim > Date: Sat Dec 17 01:36:50 2011 > New Revision: 228616 > URL: http://svn.freebsd.org/changeset/base/228616 >=20 > Log: > In usr.bin/tar/tree.c, if you really want to poke to NULL, you must use > volatile, otherwise the indirection will not be emitted. > =20 > MFC after: 1 week >=20 > Modified: > head/usr.bin/tar/tree.c >=20 > Modified: head/usr.bin/tar/tree.c > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > --- head/usr.bin/tar/tree.c Sat Dec 17 01:29:46 2011 (r228615) > +++ head/usr.bin/tar/tree.c Sat Dec 17 01:36:50 2011 (r228616) > @@ -315,7 +315,7 @@ tree_next(struct tree *t) > const char *msg =3D "Unable to continue traversing" > " directory hierarchy after a fatal error."; > write(2, msg, strlen(msg)); > - *(int *)0 =3D 1; /* Deliberate SEGV; NULL pointer dereference. */ > + *(volatile int *)0 =3D 1; /* Deliberate SEGV; NULL pointer dereference= . */ > exit(1); /* In case the SEGV didn't work. */ > } > =20 Why this hack is used instead of abort(3) or abort2(2) ? --lpp+eiGMS9nGU1lc Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (FreeBSD) iEYEARECAAYFAk7sU/MACgkQC3+MBN1Mb4hqWwCfV1fv1gU4yVIFa/joVJoIAph3 HWgAmwWe73QJ40q9P+POHVzGMZTtYK0E =XdaY -----END PGP SIGNATURE----- --lpp+eiGMS9nGU1lc--