This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: catch-throw conditions?
- From: Thiago Jung Bauermann <bauerman at br dot ibm dot com>
- To: Craig Miller <millerexpedition at gmail dot com>
- Cc: gdb at sourceware dot org
- Date: Fri, 22 Feb 2008 10:25:17 -0300
- Subject: Re: catch-throw conditions?
- References: <19143cfb0802211124k275f8f7bi765154764f42ba0@mail.gmail.com>
On Thu, 2008-02-21 at 11:24 -0800, Craig Miller wrote:
> Does anyone know if there is a way to set a condition on breakpoints
> created using the "catch throw" command? Specifically to be able to
> only cause a break when a specific C++ Exception is thrown?
>
> CentOS 4.5
> gdb Red Hat Linux (6.3.0.0-1.143.el4rh)
> gcc 3.4.6
>
> Thanks for any help you might be able to lend. I've hit a dead end
> with google and the GDB docs.
I have absolutely no experience with gdb's C++ support, but I saw with
"help catch" that gdb 6.7.1 (the current GDB release) has this command:
catch throw <exceptname> - a particular exception, when thrown
Is it available in your GDB version (which is very old, BTW)? If not, I
suggest obtaining the new GDB and trying it out.
--
[]'s
Thiago Jung Bauermann
Software Engineer
IBM Linux Technology Center