summaryrefslogtreecommitdiff
path: root/source4/auth/gensec
diff options
context:
space:
mode:
Diffstat (limited to 'source4/auth/gensec')
-rw-r--r--source4/auth/gensec/pygensec.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source4/auth/gensec/pygensec.c b/source4/auth/gensec/pygensec.c
index f8825b87d9..229a21bb53 100644
--- a/source4/auth/gensec/pygensec.c
+++ b/source4/auth/gensec/pygensec.c
@@ -203,13 +203,16 @@ static PyTypeObject Py_Security = {
.tp_flags = Py_TPFLAGS_DEFAULT,
.tp_methods = py_gensec_security_methods,
.tp_basicsize = sizeof(py_talloc_Object),
- .tp_dealloc = py_talloc_dealloc,
};
void initgensec(void)
{
PyObject *m;
+ Py_Security.tp_base = PyTalloc_GetObjectType();
+ if (Py_Security.tp_base != NULL)
+ return;
+
if (PyType_Ready(&Py_Security) < 0)
return;