I keep getting a core dump when running a C++ application on Linux. Here is part of the result upon checking the core file:
gdb someapp core.1234
GNU gdb 6.0-2mdk (Mandrake Linux)
Core was generated by `/home/someone/someapp'.
Program terminated with signal 11, Segmentation fault.
#0 0x40bfeee1 in posix_memalign () from /lib/tls/libc.so.6
#1 0x40bfc777 in mallopt () from /lib/tls/libc.so.6
#2 0x40bfb9be in calloc () from /lib/tls/libc.so.6
#3 0x4050ad05 in QImage::setNumColors(int) () from /usr/lib/qt3/lib/libqt-mt.so.3
#4 0x00000400 in ?? ()
#5 0x00000001 in ?? ()
What do frames #4 & #5 really mean? The memory is corrupted? Because when I ran:
(gdb) x 0x00000400
0x400: Cannot access memory at address 0x400
What might have caused the core dump? Can anyone shed some light on this? Thanks.