Python: fix bug with missing wrapper registration for objects created directly via the python constructor
authorGustavo J. A. M. Carneiro <gjc@inescporto.pt>
Mon, 20 Oct 2008 16:56:40 +0100
changeset 3770 33b1372d4108
parent 3769 a0946f209866
child 3771 21f40ccb03b3
Python: fix bug with missing wrapper registration for objects created directly via the python constructor
bindings/python/ns3modulegen_core_customizations.py
--- a/bindings/python/ns3modulegen_core_customizations.py	Mon Oct 20 13:31:25 2008 +0200
+++ b/bindings/python/ns3modulegen_core_customizations.py	Mon Oct 20 16:56:40 2008 +0100
@@ -424,6 +424,7 @@
         return -1;
     }
     %(CONSTRUCT_CODE)s
+    PyNs3ObjectBase_wrapper_registry[(void *) self->obj] = (PyObject *) self;
     return 0;
 }
 ''' % dict(WRAPPER_NAME=wrapper_name, PYSTRUCT=cls.pystruct, CLASS_NAME=cls.full_name,