crash @ malloc.c:2777

Andreas Jaeger aj@suse.de
Sun Oct 31 23:03:00 GMT 1999


>>>>> Isselmou Ould-Dellahy writes:

 > You're very likely right but, I think malloc's internal
 > data structures should be better protected to give a message
 > rather than crashing.
Please note that malloc is part of the C library and not part of gcc.

 > Le me add that this crash happens only on a pc under linux
 > with gcc version 2.95.1 19990816 (release).
 > I run it on HP-UX and Solaris and it works fine;
 > (I know that it can run on an other platform while
 > it contains a bug!).
 > Also I run it under "purify" and nothing was triggered.
That might happen - purify is not perfect. 
 > Right now I'm trying to minimize its size and I plan to
 > send it to the mailing list.
 > Let me mention that in this program I'm using both
 > malloc function and new operator.

Please read the libc documentation on malloc checking.  You can run
your program with MALLOC_CHECK_=1 (or 2) set in the environment for
additional internal malloc checks which might help you to see the
problem.  An alternative way to help find the bug in your program is
the mtrace program.

Andreas
-- 
 Andreas Jaeger   
  SuSE Labs aj@suse.de	
   private aj@arthur.rhein-neckar.de



More information about the Gcc-bugs mailing list