[Python-Dev] How to debug pyexpat SIGSEGV with GDB? (original) (raw)
Jeremy Hylton jeremy at alum.mit.edu
Mon Mar 1 09:53:11 EST 2004
- Previous message: [Python-Dev] Idea for a fast calling convention
- Next message: [Python-Dev] How to debug pyexpat SIGSEGV with GDB?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Fri, 2004-02-27 at 18:00, Brad Clements wrote:
So, how can I figure out where in the Python source the function call is coming from using gdb? I'm sure it involves "print" and some casts.. I couldn't find a howto on python.org
First, make sure that the code from Misc/gdbinit is in your .gdbinit file. Get the stack trace in gdb and move up/down until you get to an eval_frame() frame. Then call the function pyframe. It will print the filename, function name, and line number of the current frame. The lineno usually points to the first line of the function.
Jeremy
- Previous message: [Python-Dev] Idea for a fast calling convention
- Next message: [Python-Dev] How to debug pyexpat SIGSEGV with GDB?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]