diff options
author | Ton Roosendaal <ton@blender.org> | 2013-05-11 20:15:09 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2013-05-11 20:15:09 +0400 |
commit | 01063faf6fa8513e0afff7392dc9f111de9e5ff1 (patch) | |
tree | 99beac31dc76bacaf0df45ef945ef0f448098521 /source/blender/makesrna | |
parent | cda9407177c36793fa05ce3d3a5579c837665bc2 (diff) |
Bug fix, irc submitted
If you have three scenes, current is A, others are B and C.
B uses C as background, and C uses B as a background.
(which is possible via linked libraries)
If you then try to use B or C as background of A, code went to eternal loop.
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r-- | source/blender/makesrna/intern/rna_scene.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c index 6cbfe739898..ea0df0bf06d 100644 --- a/source/blender/makesrna/intern/rna_scene.c +++ b/source/blender/makesrna/intern/rna_scene.c @@ -453,6 +453,9 @@ static void rna_Scene_set_set(PointerRNA *ptr, PointerRNA value) for (nested_set = set; nested_set; nested_set = nested_set->set) { if (nested_set == scene) return; + /* prevent eternal loops, set can point to next, and next to set, without problems usually */ + if (nested_set->set == set) + return; } scene->set = set; |