Boost logo

Boost Users :

From: Samuel Krempp (krempp_at_[hidden])
Date: 2003-09-15 04:41:46


<posted & mailed>

le Vendredi 29 Août 2003 00:40, ssclift_at_[hidden] écrivit :

> Hi folks,
>
> There appears to be a bug in boost::format, an unitialized value
> problem spotted when I was using valgrind on a program of mine.
>
> The following test code illustrates the (admittedly minor?) problem:

Hi,

sorry for the late reply, I dont check boost.user too often, and then it
took for me to get it to accept my messages.

I dont know valgrind, and I'm not sure I can figure out the nice logs you
sent. it looks like a powerful tool, but does it say which variable is used
uninitialised ?
(and what compiler are you using format with, and does the sample code do
anything weird there ?)

I greatly doubt it is in format's code, I can find no possible reason for
different behaviour between the 2 calls, within format's code.
While in fact the stdlib's ostream code could very well do some tests and
get in trouble with 0-valued int.

Could it likely come from some code in the standard lib ?
Also, I notice some lines in the valgrind report are left unmangled, could
the analysis get mixed up at run-time for whatever reason, and detect an
unitialised value by mistake ?

regards,

-- 
Samuel
(boost::format author)

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net