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/16466] New: -break-insert does not remember a specified thread for a pending breakpoint


https://sourceware.org/bugzilla/show_bug.cgi?id=16466

            Bug ID: 16466
           Summary: -break-insert does not remember a specified thread for
                    a pending breakpoint
           Product: gdb
           Version: HEAD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: breakpoints
          Assignee: unassigned at sourceware dot org
          Reporter: marc.khouzam at ericsson dot com

When using -break-insert and specifying a thread using the -p flag, this thread
field will not be remembered for a pending breakpoint and will not be used when
that breakpoint becomes active.

This bug is very similar to Bug 16465, and probably would benefit from being
fixed together.

Below is a session that compares pending breakpoint using the CLI vs MI
interfaces:

> gdb.7.7 ~/runtime-TestDSF/myapp/Debug/myapp.exe
GNU gdb (GDB) 7.7.50.20140110-cvs
(gdb) b mydll.c:1 thread 1
No source file named mydll.c.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 1 (mydll.c:1 thread 1) pending.
(gdb) interpreter-exec mi "-break-insert -p 1 -f mydll.c:2"
&"No source file named mydll.c.\n"
^done,bkpt={number="2",type="breakpoint",disp="keep",enabled="y",addr="<PENDING>",pending="mydll.c:2",times="0",original-location="mydll.c:2"}
(gdb) inf b
Num     Type           Disp Enb Address    What
1       breakpoint     keep y   <PENDING>  mydll.c:1 thread 1
2       breakpoint     keep y   <PENDING>  mydll.c:2
(gdb) tb 18
Temporary breakpoint 3 at 0x400754: file ../src/myapp.c, line 18.
(gdb) r
Starting program: /home/lmckhou/runtime-TestDSF/myapp/Debug/myapp.exe 

Temporary breakpoint 3, main () at ../src/myapp.c:18
18           handle =
dlopen("/home/lmckhou/runtime-TestDSF/myLinuxDll/Debug/libmyLinuxDll",
RTLD_LAZY);
(gdb) n
19           if (!handle) {
(gdb) inf b
Num     Type           Disp Enb Address            What
1       breakpoint     keep y   0x00007ffff7633560 in foo at ../src/mydll.c:1
thread 1
        stop only in thread 1
2       breakpoint     keep y   0x00007ffff7633560 in foo at ../src/mydll.c:2

-- 
You are receiving this mail because:
You are on the CC list for the bug.


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