|
From: Tristan V. B. <va...@to...> - 2003-07-21 14:44:44
|
Paul Pluzhnikov wrote:
>Nicholas Nethercote wrote:
>
>
>
>>Since the memory is within a malloc'd block (so says the 2nd part of
>>the message) it should be addressable. But you say it's also
>>initialised.
>>
>>
>
>It is possible that the memory *was* initialized at some point,
>but no longer is at the time of the syscall. E.g.
>
>int main()
>{
> char buf[8];
> int x;
>
> memset(buf, 'a', sizeof(buf));
> *(int *)buf = x; /* oops -- buf is "uninitialized" again */
> write(1, buf, sizeof(buf));
>
> return 0;
>}
>
>
>
Good point. I found my bug by now but still dont know the connection to the
"unaddressable bytes" exactly (I had a race condition where I was recieving
old packets and mistaking them for a "synchronous response") I have a
feeling
the VG message had something to do with variable length packet
structures but
thats just a guess.
Thanks all,
-Tristan
|