libdrgn: python: replace return no_cleanup_ptr() with return_ptr()

They're equivalent, but return_ptr() is preferred.

Fixes: 085b0bc9db ("libdrgn: add DRGN_OBJECT scope guard")
Signed-off-by: Omar Sandoval <osandov@osandov.com>
This commit is contained in:
Omar Sandoval 2023-11-17 09:11:04 -08:00
parent fedad60425
commit f9105049de

View File

@ -587,7 +587,7 @@ static PyObject *DrgnObject_compound_value(struct drgn_object *obj,
return NULL;
}
}
return no_cleanup_ptr(dict);
return_ptr(dict);
}
static PyObject *DrgnObject_array_value(struct drgn_object *obj,
@ -624,7 +624,7 @@ static PyObject *DrgnObject_array_value(struct drgn_object *obj,
return NULL;
PyList_SET_ITEM(list, i, element_value);
}
return no_cleanup_ptr(list);
return_ptr(list);
}
static PyObject *DrgnObject_value_impl(struct drgn_object *obj)