From owner-freebsd-fs@FreeBSD.ORG Sun Apr 10 13:21:43 2005 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9E61016A4CE; Sun, 10 Apr 2005 13:21:43 +0000 (GMT) Received: from wrzx28.rz.uni-wuerzburg.de (wrzx28.rz.uni-wuerzburg.de [132.187.3.28]) by mx1.FreeBSD.org (Postfix) with ESMTP id A5DFF43D3F; Sun, 10 Apr 2005 13:21:42 +0000 (GMT) (envelope-from q@uni.de) Received: from wrzx34.rz.uni-wuerzburg.de (wrzx34.rz.uni-wuerzburg.de [132.187.3.34]) by wrzx28.rz.uni-wuerzburg.de (Postfix) with ESMTP id BC7F9D8408; Sun, 10 Apr 2005 15:21:41 +0200 (CEST) Received: from virusscan (localhost [127.0.0.1]) by wrzx34.rz.uni-wuerzburg.de (Postfix) with ESMTP id A2265AC592; Sun, 10 Apr 2005 15:21:41 +0200 (CEST) Received: from wrzx28.rz.uni-wuerzburg.de (wrzx28.rz.uni-wuerzburg.de [132.187.3.28]) by wrzx34.rz.uni-wuerzburg.de (Postfix) with ESMTP id 6AF2EA77E2; Sun, 10 Apr 2005 15:21:41 +0200 (CEST) Received: from frodo.galgenberg.net (wwsx14.win-screen.uni-wuerzburg.de [132.187.253.14]) by wrzx28.rz.uni-wuerzburg.de (Postfix) with ESMTP id 4D117D8408; Sun, 10 Apr 2005 15:21:38 +0200 (CEST) Received: from coyote.q.local (gb-21-237.galgenberg.net [172.16.21.237]) by frodo.galgenberg.net (8.13.1/8.13.1) with ESMTP id j3ADLc9H010232; Sun, 10 Apr 2005 15:21:38 +0200 (CEST) (envelope-from q@uni.de) Received: from roadrunner.q.local (roadrunner.q.local [192.168.0.148]) by coyote.q.local (8.13.1/8.13.1) with ESMTP id j3ADLbrQ016229; Sun, 10 Apr 2005 15:21:37 +0200 (CEST) (envelope-from q@uni.de) Received: from roadrunner.q.local (localhost [127.0.0.1]) by roadrunner.q.local (8.13.3/8.13.1) with ESMTP id j3ADLbTF012473; Sun, 10 Apr 2005 15:21:37 +0200 (CEST) (envelope-from q@uni.de) Received: (from q@localhost) by roadrunner.q.local (8.13.3/8.13.1/Submit) id j3ADLZpa012472; Sun, 10 Apr 2005 15:21:35 +0200 (CEST) (envelope-from q@uni.de) Date: Sun, 10 Apr 2005 15:21:35 +0200 From: Ulrich Spoerlein To: Daniel Ellard Message-ID: <20050410132135.GB774@galgenberg.net> Mail-Followup-To: Daniel Ellard , takawata@jp.freebsd.org, freebsd-fs@freebsd.org, bp@freebsd.org, jeff@freebsd.org, freebsd-current@freebsd.org References: <200504100251.j3A2pLEH055107@sana.init-main.com> <20050410092417.GA774@galgenberg.net> <20050410074009.N66651@bowser.eecs.harvard.edu> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="7ZAtKRhVyVSsbBD2" Content-Disposition: inline In-Reply-To: <20050410074009.N66651@bowser.eecs.harvard.edu> User-Agent: Mutt/1.5.8i X-Virus-Scanned: by amavisd-new (Rechenzentrum Universitaet Wuerzburg) cc: freebsd-fs@freebsd.org cc: bp@freebsd.org cc: jeff@freebsd.org cc: freebsd-current@freebsd.org Subject: Re: smbfs bug introduced at smbfs_vnops.c:1.58 X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 10 Apr 2005 13:21:43 -0000 --7ZAtKRhVyVSsbBD2 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, 10.04.2005 at 07:45:50 -0400, Daniel Ellard wrote: > Certainly this is undesireable, but from what I can tell this > happens because "a" is a dead variable and removed. (Look at > the asm output and you'll see what I mean.) So it's debatable > whether this is a bug. >=20 > If you change the -O to -g, then the code for "a" is not > removed -- but there's still no warning. I think this is > a bug, because if the expression wasn't an innocuous a+=3D1 > it could be a real problem if the variable wasn't removed. > But people will also argue about this.. You are right, using something like this: #include int main(void) { int a,b; a+=3D1; b=3D1+a; printf("%d\n", b); return (0); } I get a warning: % cc -O -W -Wall -Wuninitialized foo.c foo.c: In function `main': foo.c:3: warning: 'a' might be used uninitialized in this function Sorry for the noise then. /me needs to learn asm some day. Ulrich Sp=F6rlein --=20 PGP Key ID: F0DB9F44 Encrypted mail welcome! Fingerprint: F1CE D062 0CA9 ADE3 349B 2FE8 980A C6B5 F0DB 9F44 Ok, which part of "Ph'nglui mglw'nafh Cthulhu R'lyeh wgah'nagl fhtagn." didn't you understand? --7ZAtKRhVyVSsbBD2 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (FreeBSD) iD8DBQFCWShfmArGtfDbn0QRAiE8AJ9+UpRfN2zL4Pgj9lvXsDx8LLQKcACgxgv6 6mXAFnU8+XSLDHhh8FL2YqY= =KQlv -----END PGP SIGNATURE----- --7ZAtKRhVyVSsbBD2--