This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug gdb/12442] New: internal-error: find_inferior_pid: Assertion`pid != 0' failed.
- From: "zilla at kayari dot org" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Wed, 26 Jan 2011 11:10:12 +0000
- Subject: [Bug gdb/12442] New: internal-error: find_inferior_pid: Assertion`pid != 0' failed.
- Auto-submitted: auto-generated
http://sourceware.org/bugzilla/show_bug.cgi?id=12442
Summary: internal-error: find_inferior_pid: Assertion `pid !=
0' failed.
Product: gdb
Version: 7.2
Status: NEW
Severity: normal
Priority: P2
Component: gdb
AssignedTo: unassigned@sourceware.org
ReportedBy: zilla@kayari.org
GDB gets an internal error following these steps:
1) load an executable which segfaults and corresponding core file
2) run the executable
3) quit gdb
Here is the output of such a debugging session, using GDB 7.2 on CentOS 5.3
$ cat core.c
int main()
{
char* p = 0;
return *p;
}
$ gcc -g core.c
$
$ ./a.out
Segmentation fault (core dumped)
$
$ # lastcore just prints the name of the most recent core file
$ gdb -n ./a.out `lastcore`
GNU gdb (GDB) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /dev/shm/jwakely/a.out...done.
[New Thread 13830]
Reading symbols from /lib64/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib64/libc.so.6
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols
found)...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
Core was generated by `./a.out'.
Program terminated with signal 11, Segmentation fault.
#0 0x0000000000400464 in main () at core.c:4
4 return *p;
(gdb) r
Starting program: /dev/shm/jwakely/a.out
Program received signal SIGSEGV, Segmentation fault.
0x0000000000400464 in main () at core.c:4
4 return *p;
(gdb) q
A debugging session is active.
Inferior 1 [process 13880] will be killed.
Quit anyway? (y or n) y
inferior.c:362: internal-error: find_inferior_pid: Assertion `pid != 0' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Quit this debugging session? (y or n) y
inferior.c:362: internal-error: find_inferior_pid: Assertion `pid != 0' failed.
A problem internal to GDB has been detected,
further debugging may prove unreliable.
Create a core file of GDB? (y or n) n
$
$ gdb --version
GNU gdb (GDB) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
$
$
$ gcc -v
Using built-in specs.
Target: x86_64-unknown-linux-gnu
Configured with: /var/tmp/gcc/gcc-4.4.3/configure
--prefix=/opt/gcc-4.4-64/gcc-4.4.3 --enable-languages=c,c++,fortran
--enable-libstdcxx-debug --with-system-zlib --with-arch=core2
Thread model: posix
gcc version 4.4.3 (GCC)
--
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.