-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Hi there,

looking over the options in memcheck I fail to find one that will
immediately issue an error as soon as I copy uninitialized memory. E.g.
I have a buffer (const char* buf) bigger than the data I read, so only n
Bytes out of n+m Bytes have been written to after the allocation (no
matter whether on the stack or not).

Whenever someone uses a Byte from buf[x] with x >= n, Valgrind will
issue an error, pointing out that an uninitialized ("tainted") value was
used to decide a condition. Fine so far.

In many cases, though, I'd already consider the first access to the
tainted Bytes (e.g. when memcpy'ing it) as errors. Is there any way to
tell Valgrind to inform me about such operations right away instead of
tracking it to the point where the memory is used for a conditional?

Or perhaps there is a good reason why Valgrind doesn't have that (given
I am not blind and the option truly doesn't exist).


Thanks in advance,

// Oliver
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)

iQEcBAEBCAAGBQJLvNnnAAoJEJm+Ui/QYLFPWfsH/RPTxZLHUo0PQepyeTUafT3l
AA/C4Uqtdx4nrACGWPAWkgqdvoVl8DVrfwvWDnRUyTN+Rh53kx6Q2Td/c20DiOmK
aKfYjsex0b+X2xVzZs3KtgxTxSagNT0TxNsPpuVyDn5GsF6yY/IlcRuyLP0Fq4c/
diwGi1u7M9X5w0DNDfBGTPhqUeYMUkQOdATxratiMFEe2mfE6wJ7kq/4I95GAgd0
zpi3RLxAORj3tq6D5ONXau8GWhP9lL6CW479hWnUt7QeB/NVcRT4F3LKfOqS3Nyu
/s/WO0RHcAb45iBRPO17YzbpJEL7zk3/IutnKojtY7XJCOufC4t9BN//upFUc3Y=
=Ttxr
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Valgrind-users mailing list
Valgrind-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/valgrind-users

Reply via email to