summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2016-03-01 09:32:06 +1300
committerAndrew Bartlett <abartlet@samba.org>2016-03-08 01:58:29 +0100
commit0f35167d767e4ace2295f3025110470504f160d3 (patch)
tree4c0072a62acea3f29be710b84843d493221fcf3b
parentec5d63f9edcf311b581df4f37a702a54d659d443 (diff)
downloadsamba-0f35167d767e4ace2295f3025110470504f160d3.tar.gz
pygensec: Use pytalloc_BaseObject_PyType_Ready()
This changes pygensec to use talloc.BaseObject() just like the PIDL output Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
-rw-r--r--source4/auth/gensec/pygensec.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/source4/auth/gensec/pygensec.c b/source4/auth/gensec/pygensec.c
index 16a5326a290..33998698819 100644
--- a/source4/auth/gensec/pygensec.c
+++ b/source4/auth/gensec/pygensec.c
@@ -574,7 +574,6 @@ static PyTypeObject Py_Security = {
.tp_name = "gensec.Security",
.tp_flags = Py_TPFLAGS_DEFAULT,
.tp_methods = py_gensec_security_methods,
- .tp_basicsize = sizeof(pytalloc_Object),
};
void initgensec(void);
@@ -582,11 +581,7 @@ void initgensec(void)
{
PyObject *m;
- Py_Security.tp_base = pytalloc_GetObjectType();
- if (Py_Security.tp_base == NULL)
- return;
-
- if (PyType_Ready(&Py_Security) < 0)
+ if (pytalloc_BaseObject_PyType_Ready(&Py_Security) < 0)
return;
m = Py_InitModule3("gensec", NULL, "Generic Security Interface.");