stdcxx-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Black <>
Subject [patch]Re: examples in OUTPUT state
Date Mon, 07 Aug 2006 21:11:33 GMT
Greetings all.

Attached is a short patch that should resolve this issue.

The cause of the error was that the output was smaller than the static 
holding buffer, so the call to memcmp was comparing beyond the amount of 
data that had been read into the buffer.  This in turn was leading to a 
difference in the unfilled portions of the buffer.  This difference was 
caused by the natural variations in uninitialized memory.

--Andrew Black

Martin Sebor wrote:
> There are a bunch of examples that the exec utility reports as
> having failed with the OUTPUT status even though when executed
> by hand they run successfully to completion and produce the
> expected output. I suspect there must be a bug in the utility.
> $ make auto_ptr run; ./auto_ptr > auto_ptr.out && diff auto_ptr.out 
> /build/sebor/stdcxx/examples/manual/out/auto_ptr.out; echo $?
> make: `auto_ptr' is up to date.
> auto_ptr                  OUTPUT
> 0
> Martin

View raw message