This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug remote/17241] New: reconnecting after crashed gdbserver: breakpoints don't work, inferior segvs
- From: "dje at google dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Thu, 07 Aug 2014 18:31:24 +0000
- Subject: [Bug remote/17241] New: reconnecting after crashed gdbserver: breakpoints don't work, inferior segvs
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=17241
Bug ID: 17241
Summary: reconnecting after crashed gdbserver: breakpoints
don't work, inferior segvs
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: remote
Assignee: unassigned at sourceware dot org
Reporter: dje at google dot com
Playing with PR 17239 some more, I found "start" would run past "main" after I
restart gdbserver and reconnect, and the inferior gets a SEGV.
bash1$ ./gdbserver --multi :1234
Listening on port 1234
Remote debugging from host 127.0.0.1
Process /home/dje/hello.x64 created; pid = 17378
Cannot exec /home/dje/hello.x64 : No such file or directory.
Child exited with status 127
Process /home/dje/hello.x64 created; pid = 17426
gdbserver: no target description
[start gdbserver again after it errantly exits]
bash1$ ./gdbserver --multi :1234
Listening on port 1234
Remote debugging from host 127.0.0.1
Process /home/dje/hello.x64 created; pid = 17450
Hello. <<<< bkpt at main not hit or gdbserver loses control?
And in a second shell,
bash2$ make run
(gdb) tar ext :1234
Remote debugging using :1234
(gdb) file ~/hello.x64
Reading symbols from ~/hello.x64...done.
(gdb) set remote exec-file /home/dje/hello.x64<space>
(gdb) start
Temporary breakpoint 1 at 0x4006d8: file hello.cc, line 6.
Starting program: /usr/local/google/home/dje/hello.x64
Running "/home/dje/hello.x64 " on the remote target failed
(gdb) set remote exec-file /home/dje/hello.x64
(gdb) start
Temporary breakpoint 2 at 0x4006d8: file hello.cc, line 6.
Starting program: /usr/local/google/home/dje/hello.x64
Remote connection closed
[go back to bash1 at this point and restart gdbserver, see above]
(gdb) pwd
Working directory /foo/build/obj64/gdb.
(gdb) show remote exec-file
The remote pathname for "run" is "/home/dje/hello.x64".
(gdb) tar ext :1234
Remote debugging using :1234
(gdb) start
Temporary breakpoint 3 at 0x4006d8: file hello.cc, line 6.
Starting program: /usr/local/google/home/dje/hello.x64
Program received signal SIGSEGV, Segmentation fault.
0x000000000000000b in ?? ()
(gdb) i b
Num Type Disp Enb Address What
1 breakpoint del y 0x00000000004006d4 in main() at hello.cc:5
2 breakpoint del y 0x00000000004006d4 in main() at hello.cc:5
3 breakpoint del y 0x00000000004006d4 in main() at hello.cc:5
--
You are receiving this mail because:
You are on the CC list for the bug.