Problem debugging Assert failure.
gdb 6.8, Qt 4.2.3, MinGW environment
I'm getting an Assert failure in qbytearray.h (becausing somewhere I'm doing a .at() with an invalid index). I'm trying to catch it in console based gdb to be able to look at the stack trace to see from whence it has come. The gdb manual recommends breaking on __raise_exception for gnu c++, but gdb couldn't find that symbol; breaking on 'throw' also doesn't work.
Any suggestions on how to break on throwing an Assert error in Qt files?
Thanks, Doug
Re: Problem debugging Assert failure.
Using linux, I just run the program (debug build) in gdb and in case of an assert, it stops right there. Then I just hit "bt" in gdb and know the culprit.
Re: Problem debugging Assert failure.
I'm running in Windows and after the assert 'bt' states to the effect that 'there is no stackframe', the app apparantly has already exited when gdb gets control back.
Re: Problem debugging Assert failure.
I finally found a way to do it for anyone else with this problem, I set breakpoints on qFatal(). Worked great.
Doug