public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/12824] New: throw catchpoint doesn't catch rethrows
@ 2011-05-30 15:11 matz at suse dot de
  2013-02-25 18:51 ` [Bug c++/12824] " tromey at redhat dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: matz at suse dot de @ 2011-05-30 15:11 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=12824

           Summary: throw catchpoint doesn't catch rethrows
           Product: gdb
           Version: HEAD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned@sourceware.org
        ReportedBy: matz@suse.de


# cat bla.cc
int f (int i)
{
  try {
      if (i)
        throw;
  } catch (...) {
  }
  return i+1;
}

int main ()
{
  f(1);
  return 0;
}

# g++ bla.cc
# gdb ./a.out
(gdb) catch throw
catch throw
Function "__cxa_throw" not defined.
Catchpoint 1 (throw)
(gdb) b __cxa_rethrow
Breakpoint 1 at 0x4005a0

Perhaps it would be nice if 'catch throw' would also catch __cxa_rethrow.
As that might lead to too much noise in normal rethrow behaviour, perhaps
a new catchpoint type would be better.  One of our users ran into this and
was surprised that 'catch throw' didn't trigger on this one, and instead
it went down into the SIBABRT.

-- 
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.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-04-15 18:15 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-05-30 15:11 [Bug c++/12824] New: throw catchpoint doesn't catch rethrows matz at suse dot de
2013-02-25 18:51 ` [Bug c++/12824] " tromey at redhat dot com
2013-02-27 21:54 ` tromey at redhat dot com
2013-04-15 17:27 ` cvs-commit at gcc dot gnu.org
2013-04-15 18:14 ` tromey at redhat dot com
2013-04-15 18:15 ` tromey at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).