Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Montagne <bastien@blender.org>2020-08-11 19:49:17 +0300
committerBastien Montagne <bastien@blender.org>2020-08-11 19:49:17 +0300
commitb95aa48156bbc28beb57e1363c740fb0a0f00f38 (patch)
tree9c17665d287ce32d236e0b70c3795efd1a2e15e8 /source/blender/blenkernel/intern/collection.c
parent20ca7122f0a1a37c6b249d76abe14251baae488e (diff)
parentd2c150772a432091ac128e0fc01aef3b997e8bfb (diff)
Merge branch 'blender-v2.90-release' into master
Diffstat (limited to 'source/blender/blenkernel/intern/collection.c')
-rw-r--r--source/blender/blenkernel/intern/collection.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/collection.c b/source/blender/blenkernel/intern/collection.c
index 6d2432f53e4..0d65ee5faa3 100644
--- a/source/blender/blenkernel/intern/collection.c
+++ b/source/blender/blenkernel/intern/collection.c
@@ -408,9 +408,9 @@ static Collection *collection_duplicate_recursive(Main *bmain,
}
if (do_objects) {
- /* We can loop on collection_old's objects, that list is currently identical the collection_new
- * objects, and won't be changed here. */
- LISTBASE_FOREACH (CollectionObject *, cob, &collection_old->gobject) {
+ /* We can loop on collection_old's objects, but have to consider it mutable because with master
+ * collections collection_old and collection_new are the same data here. */
+ LISTBASE_FOREACH_MUTABLE (CollectionObject *, cob, &collection_old->gobject) {
Object *ob_old = cob->ob;
Object *ob_new = (Object *)ob_old->id.newid;