This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug breakpoints/9723] gdb core dumps on adding a breakpoint


------- Additional Comments From pedro at codesourcery dot com  2009-01-12 19:26 -------
Subject: Re:  gdb core dumps on adding a breakpoint

FWI, I've just tried this on:

 - gdb 6.8-debian: 

  Got it to crash as:

(gdb) set args -dfv
(gdb) break become_daemon
Function "become_daemon" not defined.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 1 (become_daemon) pending.
(gdb) run
Starting program: /home/pedro/downloads/automount -dfv

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7f6cfc0066e0 (LWP 30766)]
0x00000000004a7d4d in disable_breakpoints_at_startup ()

(gdb) bt
#0  0x00000000004a7d4d in disable_breakpoints_at_startup ()
#1  0x00000000004dce6f in post_create_inferior ()
#2  0x00000000004dd274 in ?? ()
#3  0x000000000044d7e2 in execute_command ()
#4  0x00000000004ee04b in ?? ()
#5  0x00000000004eecdb in ?? ()
#6  0x00007f6cfbbf6ea7 in rl_callback_read_char () from /lib/libreadline.so.5
#7  0x00000000004ee229 in ?? ()
#8  0x00000000004eccd3 in ?? ()
#9  0x00000000004ed5e8 in gdb_do_one_event ()
#10 0x00000000004ea4ab in catch_errors ()
#11 0x0000000000493876 in ?? ()
#12 0x0000000000445dc9 in ?? ()
#13 0x00000000004ea4ab in catch_errors ()
#14 0x0000000000446566 in ?? ()
#15 0x00000000004ea4ab in catch_errors ()
#16 0x0000000000445db4 in gdb_main ()
#17 0x0000000000445d86 in main ()

Now, disable_breakpoints_at_startup isn't a function that's in mainline.  This is
part of a series that adds support for PIE.  I know that there are two different
implementations that add PIE support for GDB, one from redhat, and one
from suse.  Maybe debian has the redhat version, and I'm triggering
the same bug you are.

 - vanilla FSF gdb 6.8 

(gdb) run
Starting program: /home/pedro/downloads/automount -dfv
/home/pedro/downloads/automount: this program must be run by root.

Program exited with code 01.
(gdb)   

Ok, so ...

> sudo gdb ...

(gdb) set args -dfv
(gdb) break become_daemon
Function "become_daemon" not defined.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 1 (become_daemon) pending.
(gdb) run
Starting program: /home/pedro/downloads/automount -dfv
/home/pedro/downloads/automount: test mount forbidden or incorrect kernel protocol version, kernel protocol version 5.00 or above required.

Program exited with code 01.
(gdb)

 - mainline:

  behaved the same as FSF 6.8.

I've done my best to try to reproduce this.

Can you please confirm if this happens to you with an FSF gdb?  If so, please
provide a backtrace.  Ideally, we'd get a smaller testcase, as I'm not sure
I'm seeing what you're seeing.

I'm reserving the right to close this as invalid if I don't hear back
in a week or so.  ;-)



-- 


http://sourceware.org/bugzilla/show_bug.cgi?id=9723

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]