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:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2018-06-11 22:51:21 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2018-06-11 22:51:21 +0300
commit0054dff67eb5262aabb1a0ee1f70641859044e65 (patch)
tree601e298f7f2400f25527ea8bc4497170d8bbe053 /source/blender/blenloader
parent3816502b7ca0728405d8dff8d074e3189740648a (diff)
Fix part of T55439: don't add indirectly linked objects to the scene on link.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 6aeb3e0e0cd..039af3cfa61 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -10002,13 +10002,15 @@ static void add_loose_objects_to_scene(
if ((ob->id.tag & LIB_TAG_INDIRECT) && (ob->id.tag & LIB_TAG_PRE_EXISTING) == 0) {
bool do_it = false;
- if (ob->id.us == 0) {
- do_it = true;
- }
- else if (!is_link && (ob->id.lib == lib) && (object_in_any_scene(bmain, ob) == 0)) {
- /* When appending, make sure any indirectly loaded objects get a base, else they cant be accessed at all
- * (see T27437). */
- do_it = true;
+ if (!is_link) {
+ if (ob->id.us == 0) {
+ do_it = true;
+ }
+ else if ((ob->id.lib == lib) && (object_in_any_scene(bmain, ob) == 0)) {
+ /* When appending, make sure any indirectly loaded objects get a base, else they cant be accessed at all
+ * (see T27437). */
+ do_it = true;
+ }
}
if (do_it) {