diff options
Diffstat (limited to 'source/blender/python/generic/idprop_py_api.c')
-rw-r--r-- | source/blender/python/generic/idprop_py_api.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/source/blender/python/generic/idprop_py_api.c b/source/blender/python/generic/idprop_py_api.c index f7ed5fec891..92e9f49769d 100644 --- a/source/blender/python/generic/idprop_py_api.c +++ b/source/blender/python/generic/idprop_py_api.c @@ -496,9 +496,7 @@ int BPy_Wrap_SetMapItem(IDProperty *prop, PyObject *key, PyObject *val) if (val == NULL) { /* del idprop[key] */ IDProperty *pkey = IDP_GetPropertyFromGroup(prop, _PyUnicode_AsString(key)); if (pkey) { - IDP_RemFromGroup(prop, pkey); - IDP_FreeProperty(pkey); - MEM_freeN(pkey); + IDP_FreeFromGroup(prop, pkey); return 0; } else { @@ -670,7 +668,7 @@ static PyObject *BPy_IDGroup_Pop(BPy_IDProperty *self, PyObject *value) return NULL; } - IDP_RemFromGroup(self->prop, idprop); + IDP_RemoveFromGroup(self->prop, idprop); return pyform; } |