[Python-bugs-list] [Bug #115341] Todays CVS python dumps core in gcmodule.c?!

noreply@sourceforge.net noreply@sourceforge.net
Tue, 26 Sep 2000 01:43:48 -0700


Bug #115341, was updated on 2000-Sep-26 01:43
Here is a current snapshot of the bug.

Project: Python
Category: Core
Status: Open
Resolution: None
Bug Group: None
Priority: 5
Summary: Todays CVS python dumps core in gcmodule.c?!

Details: While tracing a bug in my own code, I got a core dump from python.
Since it is extremely difficult to find out WHERE in my 58k lines of code this
happens,  I can't just make a small test case. I thought at this stage it might
be useful to report anyway.

no203[204]lehmann%3% gdb =python core        
GNU gdb 19991004
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux"...
Core was generated by `/usr/local/nonius/bin/python /usr/local/nonius/app/gui/to
p.py new orient x.non'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /lib/libdb.so.3...done.
Reading symbols from /lib/libpthread.so.0...done.
Reading symbols from /lib/libdl.so.2...done.
Reading symbols from /lib/libutil.so.1...done.
Reading symbols from /lib/libm.so.6...done.
Reading symbols from /lib/libc.so.6...done.
Reading symbols from /lib/ld-linux.so.2...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/stropmodule.so.
..done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/timemodule.so..
.done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/_tkinter.so...
done.
---Type <return> to continue, or q <return> to quit---
Reading symbols from /usr/local/nonius/lib/libBLT24.so...done.
Reading symbols from /usr/local/nonius/lib/libtk8.3.so...done.
Reading symbols from /usr/local/nonius/lib/libtcl8.3.so...done.
Reading symbols from /usr/X11R6/lib/libX11.so.6...done.
Reading symbols from /lib/libnsl.so.1...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/mathmodule.so..
.done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/md5module.so...
done.
Reading symbols from /usr/local/nonius/lib/python2.0/site-packages/Numeric/multi
array.so...done.
Reading symbols from /usr/local/nonius/lib/python2.0/site-packages/Numeric/_nump
y.so...done.
Reading symbols from /usr/local/nonius/lib/python2.0/site-packages/Numeric/umath
.so...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/structmodule.so
...done.
Reading symbols from /usr/local/nonius/app/misc/linux/_ntoolsmodule.so...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/_socketmodule.s
o...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/cStringIO.so...
done.
Reading symbols from /lib/libnss_files.so.2...done.
---Type <return> to continue, or q <return> to quit---
Reading symbols from /usr/local/nonius/lib/python2.0/site-packages/Numeric/lapac
k_lite.so...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/selectmodule.so
...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/gdbmmodule.so..
.done.
Reading symbols from /usr/lib/libgdbm.so.2...done.
Reading symbols from /usr/local/nonius/lib/python2.0/lib-dynload/cPickle.so...
done.
Reading symbols from /usr/local/nonius/lib/python2.0/site-packages/Numeric/ranli
b.so...done.
#0  update_refs (containers=0x80bfec0) at ./gcmodule.c:150
150                     gc->gc_refs = PyObject_FROM_GC(gc)->ob_refcnt;
(gdb) where
#0  update_refs (containers=0x80bfec0) at ./gcmodule.c:150
#1  0x808ae9b in collect (young=0x80bfec0, old=0x80bfecc) at ./gcmodule.c:382
#2  0x808b0cc in collect_generations () at ./gcmodule.c:488
#3  0x808b10f in _PyGC_Insert (op=0x8703824) at ./gcmodule.c:507
#4  0x807fbe4 in PyTuple_New (size=3) at tupleobject.c:87
#5  0x80561df in eval_code2 (co=0x8260518, globals=0x823fcd4, locals=0x0, 
    args=0x824d258, argcount=2, kws=0x8780190, kwcount=5, defs=0x8268f50, 
    defcount=1, owner=0x82699e4) at ceval.c:1561
#6  0x8057e3b in call_function (func=0x8269a7c, arg=0x87616cc, kw=0x87743ac)
    at ceval.c:2744
#7  0x8057a4b in PyEval_CallObjectWithKeywords (func=0x87816bc, arg=0x87616cc, 
    kw=0x87743ac) at ceval.c:2588
#8  0x806df7b in PyInstance_New (class=0x82699e4, arg=0x87616cc, kw=0x87743ac)
    at classobject.c:463
#9  0x8057b51 in call_builtin (func=0x82699e4, arg=0x87616cc, kw=0x87743ac)
    at ceval.c:2625
#10 0x8057a58 in PyEval_CallObjectWithKeywords (func=0x82699e4, arg=0x87616cc, 
    kw=0x87743ac) at ceval.c:2590
#11 0x8056bab in eval_code2 (co=0x81f0c58, globals=0x8201b1c, locals=0x0, 
    args=0x875cd8c, argcount=2, kws=0x875cd94, kwcount=0, defs=0x8201248, 
    defcount=1, owner=0x81fe94c) at ceval.c:1923
#12 0x805687c in eval_code2 (co=0x81f2de8, globals=0x8201b1c, locals=0x0, 
    args=0x866e2b0, argcount=2, kws=0x866e2b8, kwcount=0, defs=0x0, 
---Type <return> to continue, or q <return> to quit---
    defcount=0, owner=0x8201a4c) at ceval.c:1822
#13 0x805687c in eval_code2 (co=0x81ef9d0, globals=0x8201b1c, locals=0x0, 
    args=0x8203314, argcount=2, kws=0x820331c, kwcount=0, defs=0x8201098, 
    defcount=1, owner=0x81f4e8c) at ceval.c:1822
#14 0x805687c in eval_code2 (co=0x83d1d10, globals=0x83d8044, locals=0x0, 
    args=0x8202840, argcount=2, kws=0x8202848, kwcount=0, defs=0x0, 
    defcount=0, owner=0x85fc974) at ceval.c:1822
#15 0x805687c in eval_code2 (co=0x83cff98, globals=0x83d8044, locals=0x0, 
    args=0x8202068, argcount=1, kws=0x820206c, kwcount=0, defs=0x0, 
    defcount=0, owner=0x85fc974) at ceval.c:1822
#16 0x805687c in eval_code2 (co=0x83af368, globals=0x83b2574, locals=0x0, 
    args=0x86134f0, argcount=2, kws=0x0, kwcount=0, defs=0x83b2120, 
    defcount=1, owner=0x83c8b8c) at ceval.c:1822
#17 0x8057e3b in call_function (func=0x83bcc7c, arg=0x860fcac, kw=0x0)
    at ceval.c:2744
#18 0x8057a4b in PyEval_CallObjectWithKeywords (func=0x8203194, arg=0x860fcac, 
    kw=0x0) at ceval.c:2588
#19 0x806df7b in PyInstance_New (class=0x85fc974, arg=0x860fcac, kw=0x0)
    at classobject.c:463
#20 0x8057b51 in call_builtin (func=0x85fc974, arg=0x860fcac, kw=0x0)
    at ceval.c:2625
#21 0x8057a58 in PyEval_CallObjectWithKeywords (func=0x85fc974, arg=0x860fcac, 
    kw=0x0) at ceval.c:2590
---Type <return> to continue, or q <return> to quit---
#22 0x8056bab in eval_code2 (co=0x8163568, globals=0x80caecc, locals=0x0, 
    args=0x80d562c, argcount=2, kws=0x80d5634, kwcount=0, defs=0x0, 
    defcount=0, owner=0x860e81c) at ceval.c:1923
#23 0x805687c in eval_code2 (co=0x810e8f8, globals=0x80caecc, 
    locals=0x80caecc, args=0x0, argcount=0, kws=0x0, kwcount=0, defs=0x0, 
    defcount=0, owner=0x0) at ceval.c:1822
#24 0x80545d7 in PyEval_EvalCode (co=0x810e8f8, globals=0x80caecc, 
    locals=0x80caecc) at ceval.c:319
#25 0x80660b4 in run_node (n=0x80d3cc8, 
    filename=0xbffff998 "/usr/local/nonius/app/gui/top.py", globals=0x80caecc, 
    locals=0x80caecc) at pythonrun.c:886
#26 0x8066079 in run_err_node (n=0x80d3cc8, 
    filename=0xbffff998 "/usr/local/nonius/app/gui/top.py", globals=0x80caecc, 
    locals=0x80caecc) at pythonrun.c:874
#27 0x8066057 in PyRun_FileEx (fp=0x80c6e68, 
    filename=0xbffff998 "/usr/local/nonius/app/gui/top.py", start=257, 
    globals=0x80caecc, locals=0x80caecc, closeit=1) at pythonrun.c:866
#28 0x8065821 in PyRun_SimpleFileEx (fp=0x80c6e68, 
    filename=0xbffff998 "/usr/local/nonius/app/gui/top.py", closeit=1)
    at pythonrun.c:579
#29 0x80654d0 in PyRun_AnyFileEx (fp=0x80c6e68, 
    filename=0xbffff998 "/usr/local/nonius/app/gui/top.py", closeit=1)
    at pythonrun.c:459
---Type <return> to continue, or q <return> to quit---
#30 0x8051a40 in Py_Main (argc=4, argv=0xbffff814) at main.c:289
#31 0x8051566 in main (argc=5, argv=0xbffff814) at python.c:10
(gdb) 
(gdb) list
145     static void
146     update_refs(PyGC_Head *containers)
147     {
148             PyGC_Head *gc = containers->gc_next;
149             for (; gc != containers; gc=gc->gc_next) {
150                     gc->gc_refs = PyObject_FROM_GC(gc)->ob_refcnt;
151             }
152     }
153
154     static int
(gdb) print gc
$1 = (PyGC_Head *) 0x0


For detailed info, follow this link:
http://sourceforge.net/bugs/?func=detailbug&bug_id=115341&group_id=5470