summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSkip Montanaro <skip@pobox.com>2004-02-10 20:27:40 (GMT)
committerSkip Montanaro <skip@pobox.com>2004-02-10 20:27:40 (GMT)
commitf3938fd02902ca55d471f9fbb533e84560745e6e (patch)
treed12f13cd0037b4c69a08b606c487ba07eac6c08c
parent29f5933fcba949afb00af50923a7bccc07ffd94e (diff)
downloadcpython-f3938fd02902ca55d471f9fbb533e84560745e6e.zip
cpython-f3938fd02902ca55d471f9fbb533e84560745e6e.tar.gz
cpython-f3938fd02902ca55d471f9fbb533e84560745e6e.tar.bz2
need to initialize ob_type slot at run-time, at least on cygwin
-rw-r--r--Modules/itertoolsmodule.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/Modules/itertoolsmodule.c b/Modules/itertoolsmodule.c
index ebd5f6d..517975b 100644
--- a/Modules/itertoolsmodule.c
+++ b/Modules/itertoolsmodule.c
@@ -413,7 +413,7 @@ teedataobject_dealloc(teedataobject *tdo)
PyDoc_STRVAR(teedataobject_doc, "Data container common to multiple tee objects.");
static PyTypeObject teedataobject_type = {
- PyObject_HEAD_INIT(&PyType_Type)
+ PyObject_HEAD_INIT(0) /* Must fill in type value later */
0, /* ob_size */
"itertools.tee_dataobject", /* tp_name */
sizeof(teedataobject), /* tp_basicsize */
@@ -2465,6 +2465,7 @@ inititertools(void)
NULL
};
+ teedataobject_type.ob_type = &PyType_Type;
m = Py_InitModule3("itertools", module_methods, module_doc);
for (i=0 ; typelist[i] != NULL ; i++) {