diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2018-06-12 13:38:54 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2018-06-12 13:38:54 +0300 |
commit | c98b2e74df2e531726f5ceabe76342282f695f23 (patch) | |
tree | b1ce1ce48658847da18ee13550583e661b194ec6 /source/blender/blenkernel/intern/library.c | |
parent | fdd26faa49f056702b63a3b60d0da051c3f77c68 (diff) | |
parent | 5508b572ea9bb2d3b758cae6898035005e8ebb2a (diff) |
Merge branch 'master' into blender2.8
Conflicts:
source/blender/editors/object/object_add.c
source/blender/editors/object/object_relations.c
Diffstat (limited to 'source/blender/blenkernel/intern/library.c')
-rw-r--r-- | source/blender/blenkernel/intern/library.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/library.c b/source/blender/blenkernel/intern/library.c index a885f22b739..2327da82615 100644 --- a/source/blender/blenkernel/intern/library.c +++ b/source/blender/blenkernel/intern/library.c @@ -772,9 +772,10 @@ bool id_single_user(bContext *C, ID *id, PointerRNA *ptr, PropertyRNA *prop) if (id) { /* if property isn't editable, we're going to have an extra block hanging around until we save */ if (RNA_property_editable(ptr, prop)) { - if (id_copy(CTX_data_main(C), id, &newid, false) && newid) { + Main *bmain = CTX_data_main(C); + if (id_copy(bmain, id, &newid, false) && newid) { /* copy animation actions too */ - BKE_animdata_copy_id_action(id, false); + BKE_animdata_copy_id_action(bmain, id, false); /* us is 1 by convention, but RNA_property_pointer_set * will also increment it, so set it to zero */ newid->us = 0; |