This is the mail archive of the insight@sources.redhat.com mailing list for the Insight 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]

[patch] catch errors restoring breakpoints


In rare cases, session breakpoints cannot be restored because sources
changed or symbols are not yet loaded.  Instead of displaying a
backtrace, just log the error.


2003-02-03  Martin M. Hunt  <hunt@redhat.com>

	* library/session.tcl (_recreate_bps): Catch errors.


Index: library/session.tcl
===================================================================
RCS file: /cvs/src/src/gdb/gdbtk/library/session.tcl,v
retrieving revision 1.13
diff -u -r1.13 session.tcl
--- library/session.tcl	10 Oct 2002 19:39:28 -0000	1.13
+++ library/session.tcl	4 Feb 2003 07:15:24 -0000
@@ -122,7 +122,9 @@
       lassign $spec create enabled condition commands
 
       # Create the breakpoint
-      gdb_cmd $create
+      if {[catch {gdb_cmd $create} txt]} {
+	dbug W $txt
+      }
 
       # Below we use `\$bpnum'.  This means we don't have to figure out
       # the number of the breakpoint when doing further manipulations.

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