summaryrefslogtreecommitdiff
path: root/lib/talloc/pytalloc.h
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2009-07-30 20:04:42 +0200
committerJelmer Vernooij <jelmer@samba.org>2009-07-30 20:04:42 +0200
commit6768cfe624fffef13109989e9cc79ccb4df13d19 (patch)
tree118d663f818c26bd28afbfded01dc8fd6651402e /lib/talloc/pytalloc.h
parenteda7f35bc891ca4a7505ec054a2b4591c6edfb38 (diff)
downloadsamba-6768cfe624fffef13109989e9cc79ccb4df13d19.tar.gz
samba-6768cfe624fffef13109989e9cc79ccb4df13d19.tar.bz2
samba-6768cfe624fffef13109989e9cc79ccb4df13d19.zip
DCE/RPC(Python): Rename py_talloc_import to py_talloc_steal.
Use py_talloc_reference in DCE/RPC code, fixes access to SAMR pipe.
Diffstat (limited to 'lib/talloc/pytalloc.h')
-rw-r--r--lib/talloc/pytalloc.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/talloc/pytalloc.h b/lib/talloc/pytalloc.h
index 00282c4ba0..3bfb272958 100644
--- a/lib/talloc/pytalloc.h
+++ b/lib/talloc/pytalloc.h
@@ -42,13 +42,14 @@ void py_talloc_dealloc(PyObject* self);
#define py_talloc_get_ptr(py_obj) (((py_talloc_Object *)py_obj)->ptr)
#define py_talloc_get_mem_ctx(py_obj) ((py_talloc_Object *)py_obj)->talloc_ctx
-PyObject *py_talloc_import_ex(PyTypeObject *py_type, TALLOC_CTX *mem_ctx, void *ptr);
-PyObject *py_talloc_reference(PyTypeObject *py_type, void *ptr);
-#define py_talloc_import(py_type, talloc_ptr) py_talloc_import_ex(py_type, talloc_ptr, talloc_ptr)
+PyObject *py_talloc_steal_ex(PyTypeObject *py_type, TALLOC_CTX *mem_ctx, void *ptr);
+PyObject *py_talloc_reference_ex(PyTypeObject *py_type, TALLOC_CTX *mem_ctx, void *ptr);
+#define py_talloc_steal(py_type, talloc_ptr) py_talloc_steal_ex(py_type, talloc_ptr, talloc_ptr)
+#define py_talloc_reference(py_type, talloc_ptr) py_talloc_reference_ex(py_type, talloc_ptr, talloc_ptr)
/* Sane default implementation of reprfunc. */
PyObject *py_talloc_default_repr(PyObject *py_obj);
-#define py_talloc_new(type, typeobj) py_talloc_import(typeobj, talloc_zero(NULL, type))
+#define py_talloc_new(type, typeobj) py_talloc_steal(typeobj, talloc_zero(NULL, type))
#endif /* _PY_TALLOC_H_ */