This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug breakpoints/15501] New: 'disable 3.1 3.2 3.3' doesn't work as expected.
- From: "palves at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Mon, 20 May 2013 16:44:38 +0000
- Subject: [Bug breakpoints/15501] New: 'disable 3.1 3.2 3.3' doesn't work as expected.
- Auto-submitted: auto-generated
http://sourceware.org/bugzilla/show_bug.cgi?id=15501
Bug #: 15501
Summary: 'disable 3.1 3.2 3.3' doesn't work as expected.
Product: gdb
Version: HEAD
Status: NEW
Severity: normal
Priority: P2
Component: breakpoints
AssignedTo: unassigned@sourceware.org
ReportedBy: palves@redhat.com
Classification: Unclassified
While "disable 1 2 3 4" works as expected, if one passes location numbers
instead of breakpoint numbers, then only the first location is updated. Vis:
(gdb) info breakpoints
No breakpoints or watchpoints.
(gdb) b main
Breakpoint 2 at 0x4004cf: file main.c, line 5.
(gdb) b main
Note: breakpoint 2 also set at pc 0x4004cf.
Breakpoint 3 at 0x4004cf: file main.c, line 5.
(gdb) info breakpoints
Num Type Disp Enb Address What
2 breakpoint keep y 0x00000000004004cf in main at main.c:5
3 breakpoint keep y 0x00000000004004cf in main at main.c:5
(gdb) disable 2 3
(gdb) info breakpoints
Num Type Disp Enb Address What
2 breakpoint keep n 0x00000000004004cf in main at main.c:5
3 breakpoint keep n 0x00000000004004cf in main at main.c:5
(gdb) enable 2 3
(gdb) info breakpoints
Num Type Disp Enb Address What
2 breakpoint keep y 0x00000000004004cf in main at main.c:5
3 breakpoint keep y 0x00000000004004cf in main at main.c:5
(gdb) disable 2.1 3.1
(gdb) info breakpoints
Num Type Disp Enb Address What
2 breakpoint keep y <MULTIPLE>
2.1 n 0x00000000004004cf in main at main.c:5
3 breakpoint keep y 0x00000000004004cf in main at main.c:5
(gdb) enable 2.1 3.1
(gdb) info breakpoints
Num Type Disp Enb Address What
2 breakpoint keep y 0x00000000004004cf in main at main.c:5
3 breakpoint keep y 0x00000000004004cf in main at main.c:5
In fact, everything after the first location is ignored:
(gdb) disable 2.1 foofoobar
(gdb) info breakpoints
Num Type Disp Enb Address What
2 breakpoint keep y <MULTIPLE>
2.1 n 0x00000000004004cf in main at main.c:5
3 breakpoint keep y 0x00000000004004cf in main at main.c:5
(gdb)
That should warn, just like:
(gdb) disable 2 foofoobar
warning: bad breakpoint number at or near 'foofoobar'
--
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.