Valgrind warning cleanup...
leslie.polzer at gmx.net
leslie.polzer at gmx.net
Sun May 14 13:06:27 CDT 2006
On Sat, May 13, 2006 at 01:36:54PM -0700, Dan Kegel wrote:
> There's another valgrind warning that is much more understandable, and
> I'm sending an obvious fix for it to wine-patches. (My first patch
> missed one instance, so I'm resending.) I'd appreciate it if you could
> check that one, too. - Dan
Sorry for taking a bit of time. Here goes:
> + memset( ldtent, 0, sizeof(*ldtent) ); /* Keep valgrind happy */
I'd never do anything like that (i.e. doing something where you have to
put a comment besides that it's there to please lint, valgrind or what
else code checkers there are (compilers excluded for obvious reasons).
> + /* memset above already cleared *ldtent */
Isn't this obvious?
> + *entry = null_entry; /* Keep valgrind happy */
This one is an exception. It replaces the two lines removed in context
and makes the code more readable -- the comment does therefore not
describe the benefits accurately and should IMO be removed.
All the best,
Leslie
--
gpg --keyserver pgp.mit.edu --recv-keys 0x52D70289
http://nic-nac-project.de/~skypher/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-devel/attachments/20060514/f5287bce/attachment.pgp
More information about the wine-devel
mailing list