This is the mail archive of the archer@sourceware.org mailing list for the Archer 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]

Re: [RFC] Patch for gnats pr 2495


Doug Evans wrote:

Hi Doug,

On Wed, Oct 22, 2008 at 8:15 AM, Phil Muldoon wrote:
should read:
+  if (unwind_on_terminating_exception_p)
+    {
+      tm = lookup_minimal_symbol ("std::terminate()", NULL, NULL);
+      if (tm != NULL)
+       {
+         terminate_bp = set_momentary_breakpoint_at_pc
+           (SYMBOL_VALUE_ADDRESS (tm),  bp_breakpoint);
+         make_cleanup_delete_breakpoint (terminate_bp);
+       }
+    }


Hi. If the inferior exits gdb will now crash in the call to inferior_thread:


if ((terminate_bp != NULL) &&
(inferior_thread()->stop_bpstat->breakpoint_at->address
== terminate_bp->loc->address))


Good catch, and thanks for taking the time to fix this.


I'll submit the attached patch upstream as while gdb doesn't crash,
the error message it currently prints is confusing.
Shall I check it into archer or the exception-rewind branch?


Personally I'd check it into the exception-rewind-branch. Archer and that branch are as yet two separate branches. As this fixes a crashing bug in that branch, and fixes a confusing message upstream. Can twiddle the bits later to make the "eventual" merge of archer-rewind happy.


Regards


Phil


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