views:

280

answers:

2

Hello! I need to debug the program with gdb (the program itself is Qt GUI program compiled with MinGW). Particularly, program hangs at some points and I need to examine call stack. But pressing Ctrl+C seems to behave strangely -- at some points not working at all. For example, if program shows a dialog box, and I press Ctrl+C, gdb does not break the program until the dialog box is dismissed, which is pretty unusable in a situation.

So, please, tell me how to break execution loop at random point using keyboard input in GDB? Sorry for possibly lame term, I'm not quite acquainted with this. Thanks in advance

A: 

Thanks to friend of mine, I found a solution here: http://cygwin.com/ml/cygwin/2006-06/msg00321.html

Andy
A: 

To obtain a call stack you might also use the pstack utility

steve