|
Boost : |
From: Paul C. Kunysch (Illume_at_[hidden])
Date: 2001-03-06 06:58:17
> OK, I will clearly have to try to make this
> work with Python 2.0. I've installed it, but
> haven't tried to use it yet.
>
> 1. Can you tell me why you thought the proposed
> changes would fix your problem?
If all objects are added to the global linked-list
properly the next- and prev-pointers won't be
NULL and python won't crash.
> 2. Can you send me an exact description of the
> change you applied to your local copy (i.e. a patch)?
(Based on 1_20_1:)
diff -u src_orig/extension_class.cpp src/extension_class.cpp
--- src_orig/extension_class.cpp Wed Nov 29 08:41:50 2000
+++ src/extension_class.cpp Wed Feb 07 21:37:03 2001
@@ -448,6 +448,7 @@
{
ob_refcnt = 1;
ob_type = &type_obj;
+ PyObject_INIT(this, &type_obj); // ###
}
operator_dispatcher*
diff -u src_orig/functions.cpp src/functions.cpp
--- src_orig/functions.cpp Sun Nov 26 10:48:26 2000
+++ src/functions.cpp Wed Feb 07 23:04:01 2001
@@ -106,7 +106,9 @@
free_list = result->m_free_list_link;
result->m_target = target;
result->m_unbound_function = fn;
- Py_INCREF(result);
+
+ PyObject_INIT(result, result->ob_type);
+
return result;
}
Bye
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk