This is the mail archive of the
mailing list for the Archer project.
[python] fix python breakpoint-saving bug
- From: Tom Tromey <tromey at redhat dot com>
- To: Project Archer <archer at sourceware dot org>
- Date: Thu, 02 Jul 2009 16:38:20 -0600
- Subject: [python] fix python breakpoint-saving bug
- Reply-to: Tom Tromey <tromey at redhat dot com>
Roland pointed out a goof in the breakpoint-saving command.
When restoring a disabled breakpoint, the number may have changed.
So, we use $bpnum in this case.
diff --git a/gdb/python/lib/gdb/command/save_breakpoints.py b/gdb/python/lib/gdb/command/save_breakpoints.py
index 90e07db..6143187 100644
@@ -50,7 +50,7 @@ The breakpoints can be restored using the 'source' command."""
print >> f, " if", bp.condition,
print >> f
if not bp.enabled:
- print >> f, "disable %d" % bp.number
+ print >> f, "disable $bpnum"
# Note: we don't save the ignore count; there doesn't
# seem to be much point.
commands = bp.commands