--- ./CXX/Python2/ExtensionOldType.hxx-memleak_fix 2011-07-26 17:32:57.230429675 +0200 +++ ./CXX/Python2/ExtensionOldType.hxx 2011-07-26 17:34:05.384066472 +0200 @@ -178,7 +178,7 @@ namespace Py Tuple self( 2 ); self[0] = Object( this ); - self[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ) ); + self[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ), true ); PyObject *func = PyCFunction_New( &method_def->ext_meth_def, self.ptr() ); --- ./CXX/Python2/ExtensionModule.hxx-memleak_fix 2011-07-26 17:34:21.287470428 +0200 +++ ./CXX/Python2/ExtensionModule.hxx 2011-07-26 17:35:49.331193448 +0200 @@ -139,8 +139,8 @@ namespace Py static PyObject *self = PyCObject_FromVoidPtr( this, do_not_dealloc ); Tuple args( 2 ); - args[0] = Object( self ); - args[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ) ); + args[0] = Object( self, true ); + args[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ), true ); PyObject *func = PyCFunction_New ( --- ./CXX/Python3/ExtensionModule.hxx.memleak_fix 2011-07-26 18:55:45.910115406 +0200 +++ ./CXX/Python3/ExtensionModule.hxx 2011-07-26 18:56:55.327162541 +0200 @@ -137,8 +137,8 @@ namespace Py static PyObject *self = PyCObject_FromVoidPtr( this, do_not_dealloc ); Tuple args( 2 ); - args[0] = Object( self ); - args[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ) ); + args[0] = Object( self, true ); + args[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ), true ); PyObject *func = PyCFunction_New ( --- ./CXX/Python3/ExtensionOldType.hxx.memleak_fix 2011-07-26 18:54:39.309749026 +0200 +++ ./CXX/Python3/ExtensionOldType.hxx 2011-07-26 18:55:25.346669091 +0200 @@ -178,7 +178,7 @@ namespace Py Tuple self( 2 ); self[0] = Object( this ); - self[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ) ); + self[1] = Object( PyCObject_FromVoidPtr( method_def, do_not_dealloc ), true ); PyObject *func = PyCFunction_New( &method_def->ext_meth_def, self.ptr() );