need help porting ctypes to Linux

Michael Hudson mwh at python.net
Wed Nov 20 07:57:38 EST 2002


Thomas Heller <theller at python.net> writes:

> Michael Hudson <mwh at python.net> writes:
> 
> > Try executing
> > 
> > ulimit -c unlimited
> > 
> > before running your program.
> 
> Yup, works now.

Cool.

> > > Do I have to enable this?  Or is it possible to configure gdb so
> > > that it will automatically pop up to examine the program's state?
> > 
> > If you run your program under gdb (i.e. execute
> > 
> > $ gdb python
> > 
> > and type "run") then any signal -- including sig 11 -- will dump you
> > into gdb.
> 
> Ok, so I'll have to put a 'rawinput()' before the crashing code,
> and then press ^C, and set my breakpoints.

Usually I let gdb start python up as far as the interactive prompt,
use ^Z to get back to gdb, set breakpoints, use 'c' to continue my
program and run the problem code interactively.  In particular, using
^Z may be less confusing than using ^C.  Not sure, though.

Cheers,
M.

-- 
  Premature optimization is the root of all evil.
       -- Donald E. Knuth, Structured Programming with goto Statements



More information about the Python-list mailing list