You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Martin, I think this has to do with your changes to
iconv_codec.
After cvs update; configure; make, I get a seg fault on
exit of the interpreter after doing nothing other than
typing ctrl-D. This is on Linux (RedHat 8.0).
+ ./python
Python 2.3a1 (#1, Jan 27 2003, 11:06:58)
[GCC 3.2 2002090 (Red Hat Linux 8.0 3.2-7)] on linux2
Type "help", "copyright", "credits" or "license" for
more information.
>>
Memory fault
However:
+ ./python -S
Python 2.3a1 (#1, Jan 27 2003, 11:06:58)
[GCC 3.2 2002090 (Red Hat Linux 8.0 3.2-7)] on linux2
Type "help", "copyright", "credits" or "license" for
more information.
>>
Stack trace:
(gdb) bt
#0 0x0808606c in type_dealloc (type=0x4001d400)
at ../Objects/typeobject.c:1998 #1 0x08073179 in dict_dealloc (mp=0x400f4a44) at
../Objects/dictobject.c:686 #2 0x08073179 in dict_dealloc (mp=0x4009a8ac) at
../Objects/dictobject.c:686 #3 0x080bcb1d in _PyImport_Fini () at
../Python/import.c:224 #4 0x080c57b4 in Py_Finalize () at
../Python/pythonrun.c:232 #5 0x08054b1d in Py_Main (argc=1, argv=0xbffff5e4) at
../Modules/main.c:457 #6 0x0805431a in main (argc=1, argv=0xbffff5e4) at
../Modules/python.c:23 #7 0x420158d4 in __libc_start_main () from
/lib/i686/libc.so.6
I'm surprised that it happens in this way for you, though,
since normally, importing site.py won't import _iconv_codec.
The only explanation is that you have changed site.py in
some way.
The reason _iconv_codec got imported is because I have
JapanesCodecs installed which is imported by addpackage in
site.py. And JapaneseCodecs imports encodings which in turn
imports iconv_codecs.
Activity
sjoerdmullender commentedon Jan 27, 2003
Martin, I think this has to do with your changes to
iconv_codec.
After cvs update; configure; make, I get a seg fault on
exit of the interpreter after doing nothing other than
typing ctrl-D. This is on Linux (RedHat 8.0).
+ ./python
Python 2.3a1 (#1, Jan 27 2003, 11:06:58)
[GCC 3.2 2002090 (Red Hat Linux 8.0 3.2-7)] on linux2
Type "help", "copyright", "credits" or "license" for
more information.
However:
+ ./python -S
Python 2.3a1 (#1, Jan 27 2003, 11:06:58)
[GCC 3.2 2002090 (Red Hat Linux 8.0 3.2-7)] on linux2
Type "help", "copyright", "credits" or "license" for
more information.
Stack trace:
(gdb) bt
#0 0x0808606c in type_dealloc (type=0x4001d400)
at ../Objects/typeobject.c:1998
#1 0x08073179 in dict_dealloc (mp=0x400f4a44) at
../Objects/dictobject.c:686
#2 0x08073179 in dict_dealloc (mp=0x4009a8ac) at
../Objects/dictobject.c:686
#3 0x080bcb1d in _PyImport_Fini () at
../Python/import.c:224
#4 0x080c57b4 in Py_Finalize () at
../Python/pythonrun.c:232
#5 0x08054b1d in Py_Main (argc=1, argv=0xbffff5e4) at
../Modules/main.c:457
#6 0x0805431a in main (argc=1, argv=0xbffff5e4) at
../Modules/python.c:23
#7 0x420158d4 in __libc_start_main () from
/lib/i686/libc.so.6
And the reason I think Martin has something to do with
it (note the tp_name field):
(gdb) p *type
$2 = {ob_refcnt = 0, ob_type = 0x8104b20, ob_size = 0,
tp_name = 0x4001cbf2 "iconvcodec", tp_basicsize = 20,
tp_itemsize = 0,
tp_dealloc = 0x4001c81e <iconvcodec_dealloc>,
tp_print = 0, tp_getattr = 0,
tp_setattr = 0, tp_compare = 0, tp_repr = 0x4001c8ca
<iconvcodec_repr>,
tp_as_number = 0x0, tp_as_sequence = 0x0,
tp_as_mapping = 0x0, tp_hash = 0,
tp_call = 0, tp_str = 0, tp_getattro = 0x807786a
<PyObject_GenericGetAttr>,
tp_setattro = 0, tp_as_buffer = 0x0, tp_flags = 17899,
tp_doc = 0x4001d020 "iconvcodec object", tp_traverse
= 0, tp_clear = 0,
tp_richcompare = 0, tp_weaklistoffset = 0, tp_iter =
0, tp_iternext = 0,
tp_methods = 0x4001d3c0, tp_members = 0x0, tp_getset
= 0x0, tp_base = 0x0,
tp_dict = 0x0, tp_descr_get = 0, tp_descr_set = 0,
tp_dictoffset = 0,
tp_init = 0, tp_alloc = 0x80833e6 <PyType_GenericAlloc>,
tp_new = 0x4001c5c4 <iconvcodec_new>, tp_free =
0x80ccc0e <PyObject_GC_Del>,
tp_is_gc = 0, tp_bases = 0x0, tp_mro = 0x0, tp_cache
= 0x0,
tp_subclasses = 0x0, tp_weaklist = 0x0, tp_del = 0}
loewis commentedon Jan 27, 2003
Logged In: YES
user_id=21627
This is fixed in _iconv_codec.c 1.4.
I'm surprised that it happens in this way for you, though,
since normally, importing site.py won't import _iconv_codec.
The only explanation is that you have changed site.py in
some way.
sjoerdmullender commentedon Jan 27, 2003
Logged In: YES
user_id=43607
The reason _iconv_codec got imported is because I have
JapanesCodecs installed which is imported by addpackage in
site.py. And JapaneseCodecs imports encodings which in turn
imports iconv_codecs.
Things work now thanks to your fix. Thanks.