[Bf-blender-cvs] [75e85f1c9f1] master: Fix T71806: BMElem.copy_from(other) failed

Campbell Barton noreply at git.blender.org
Tue Nov 26 06:31:27 CET 2019


Commit: 75e85f1c9f1e83e3be016d3c8d8748d88e4942c4
Author: Campbell Barton
Date:   Tue Nov 26 16:28:58 2019 +1100
Branches: master
https://developer.blender.org/rB75e85f1c9f1e83e3be016d3c8d8748d88e4942c4

Fix T71806: BMElem.copy_from(other) failed

Don't modify the Python reference when copying custom-data.

===================================================================

M	source/blender/python/bmesh/bmesh_py_types.c

===================================================================

diff --git a/source/blender/python/bmesh/bmesh_py_types.c b/source/blender/python/bmesh/bmesh_py_types.c
index 89d15edb0bd..af595de2ee4 100644
--- a/source/blender/python/bmesh/bmesh_py_types.c
+++ b/source/blender/python/bmesh/bmesh_py_types.c
@@ -1543,7 +1543,7 @@ static PyObject *bpy_bm_elem_copy_from(BPy_BMElem *self, BPy_BMElem *value)
   }
 
   if (value->ele != self->ele) {
-    BM_elem_attrs_copy(value->bm, self->bm, value->ele, self->ele);
+    BM_elem_attrs_copy_ex(value->bm, self->bm, value->ele, self->ele, 0xff, CD_MASK_BM_ELEM_PYPTR);
   }
 
   Py_RETURN_NONE;



More information about the Bf-blender-cvs mailing list