I can't seem to get a proper backtrace in gdb. Not
sure if I'm missing something or if it is a bug
(according to the docs the backtrace should work, I think).
I'm using the gcc-3.3.3 bounds-checking extension on
Debian 3.1 (x686). The compiler itself builds fine.
To test it, I've compiled cvs with CFLAGS="-g
-fbounds-checking" and run the cvs testsuite (which
triggers some out-of-bounds failures).
With gdb-5.3 the output is as below... the backtrace
stops at abort() and I can't get past it.
Thanks for any suggestions you can offer -- this is a
great tool. I used to use checkergcc, but that was
getting out of date and was much slower. I have
already fixed a couple of bugs in the GNU Scientific
Library using -fbounds-checking, and I am writing an
article about it so I can refer people to it.
Network Theory Ltd,
Publishing Free Software Manuals ---
GNU gdb 5.3
Copyright 2002 Free Software Foundation, Inc.
This GDB was configured as "i686-pc-linux-gnu"...
(gdb) run -q ci -m add-it topfile
Starting program: /home/ftp/cvs-1.11.14/src/cvs -q ci
-m add-it topfile
RCS file: /tmp/cvs-sanity/cvsroot/topfile,v
Checking in topfile;
/tmp/cvs-sanity/cvsroot/topfile,v <-- topfile
initial revision: 1.1
rcs.c:3652:Bounds error: NULL or ILLEGAL pointer
argument used in memchr.
rcs.c:3652: Pointer value: NULL
Program received signal SIGABRT, Aborted.
0x4008c781 in kill () from /lib/libc.so.6
#0 0x4008c781 in kill () from /lib/libc.so.6
#1 0x4008c464 in raise () from /lib/libc.so.6
#2 0x4008dbe1 in abort () from /lib/libc.so.6