Date: Mon, 13 Sep 2004 03:12:53 +0000 From: Dima Dorfman <dd@freebsd.org> To: Dan Lukes <dan@obluda.cz> Cc: keramida@freebsd.org Subject: Re: bin/71628: [PATCH] cleanup of the usr.sbin/rpcbind code Message-ID: <20040913031253.GD42003@trit.org> In-Reply-To: <200409130100.i8D10xDG057337@freefall.freebsd.org> References: <200409130100.i8D10xDG057337@freefall.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
[talking about constructs like this: SVCXPRT *my_xprt = my_xprt;] Dan Lukes <dan@obluda.cz> wrote: > On Sun, 12 Sep 2004, Giorgos Keramidas wrote: > > No. I don't know why you think that this is a good fix for all the > > uninitialized pointer warnings. It's not. Never :-/ > > Why ? It's written within the "description" section of the PR. > Warning shoult be "attention marks" - THIS CONSTRUCT SHOULD BE REVIEWED. Any initialization in the form "T v = v" invokes undefined behavior by using the indeterminate value of an object. Eliminating a warning or saving one instruction is never worth having broken code. If the compiler can't be convinced that the variable is never used before being initialized, please initialize it to something obviously bogus. Dima.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040913031253.GD42003>