stdcxx-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nicole Willson" <will...@roguewave.com>
Subject RE: problem in temp_buffer
Date Tue, 25 Jul 2006 18:47:38 GMT
Actually the message is the header guard corruption message.  For some
reason hdr->self_ is 0xffffffff on the second time through the for loop.


-----Original Message-----
From: Martin Sebor [mailto:sebor@roguewave.com] 
Sent: Tuesday, July 25, 2006 12:45 PM
To: stdcxx-dev@incubator.apache.org
Subject: Re: problem in temp_buffer

Nicole Willson wrote:
> The stack trace is:
> #0  0x0feb0ca8 in raise () from /lib/tls/libc.so.6
> #1  0x0feb26c4 in abort () from /lib/tls/libc.so.6
> #2  0x1000eaa4 in find_block (ptr=0x77e00d48, check_heap=true,
> caller=0x0)
>     at ../new.cpp:142

This looks like it's coming from the heap debugging library and could be
caused by a corrupted header guard (see below). Is there any error
message? (If not, you might need to flush stderr in the function to see
it).

$ svn cat
http://svn.apache.org/repos/asf/incubator/stdcxx/trunk/tests/src/new.cpp

| cat -n | head -150 | tail -15
    136
    137          if (check_heap) {
    138              // check the lead guard
    139              if (hdr->self_ != hdr) {
    140                  rw_error (0, 0, __LINE__,
    141                            "%s:%d: header guard corruption at
%#p: "
    142                            "expected %#p, got %#p",
    143                            hdr->ptr_, (const void*)hdr,
hdr->self_);
    144                  abort ();
    145              }
    146
    147              // check that the stored pointer has the expected
value
    148              if (hdr->ptr_ != hdr + 1) {
    149                  rw_error (0, 0, __LINE__,
    150                            "%s:%d: block address mismatch: "

Martin

Mime
View raw message