summaryrefslogtreecommitdiff
path: root/lib/talloc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/talloc')
-rw-r--r--lib/talloc/pytalloc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/talloc/pytalloc.c b/lib/talloc/pytalloc.c
index 5ed88eca88..4e0b2eca2b 100644
--- a/lib/talloc/pytalloc.c
+++ b/lib/talloc/pytalloc.c
@@ -47,6 +47,7 @@ PyObject *py_talloc_steal_ex(PyTypeObject *py_type, TALLOC_CTX *mem_ctx,
if (talloc_steal(ret->talloc_ctx, mem_ctx) == NULL) {
return NULL;
}
+ talloc_set_name_const(ret->talloc_ctx, py_type->tp_name);
ret->ptr = ptr;
return (PyObject *)ret;
}
@@ -67,6 +68,7 @@ PyObject *py_talloc_reference_ex(PyTypeObject *py_type, TALLOC_CTX *mem_ctx, voi
if (talloc_reference(ret->talloc_ctx, mem_ctx) == NULL) {
return NULL;
}
+ talloc_set_name_const(ret->talloc_ctx, py_type->tp_name);
ret->ptr = ptr;
return (PyObject *)ret;
}