diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2010-12-01 00:03:00 +0100 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2010-12-01 01:48:25 +0100 |
commit | f43ffed781196d25a7230f6cfd6abcaf6e5d85f6 (patch) | |
tree | 17649e9051458ed60624728e918bc140b1e2b9b0 /source4/auth | |
parent | fce73d7eff516a981795efa902339cd5bfb19810 (diff) | |
download | samba-f43ffed781196d25a7230f6cfd6abcaf6e5d85f6.tar.gz samba-f43ffed781196d25a7230f6cfd6abcaf6e5d85f6.tar.bz2 samba-f43ffed781196d25a7230f6cfd6abcaf6e5d85f6.zip |
pyauth: Use talloc.Object.
Diffstat (limited to 'source4/auth')
-rw-r--r-- | source4/auth/pyauth.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source4/auth/pyauth.c b/source4/auth/pyauth.c index c2a5e408c7..2ef5ebb882 100644 --- a/source4/auth/pyauth.c +++ b/source4/auth/pyauth.c @@ -25,12 +25,10 @@ #include "libcli/security/security.h" -PyTypeObject PyAuthSession = { +static PyTypeObject PyAuthSession = { .tp_name = "AuthSession", .tp_basicsize = sizeof(py_talloc_Object), - .tp_dealloc = py_talloc_dealloc, .tp_flags = Py_TPFLAGS_DEFAULT, - .tp_repr = py_talloc_default_repr, }; PyObject *PyAuthSession_FromSession(struct auth_session_info *session) @@ -114,6 +112,10 @@ void initauth(void) { PyObject *m; + PyAuthSession.tp_base = PyTalloc_GetObjectType(); + if (PyAuthSession.tp_base == NULL) + return; + if (PyType_Ready(&PyAuthSession) < 0) return; |