diff options
author | Bastien Montagne <bastien@blender.org> | 2022-01-25 18:42:31 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2022-01-25 18:44:55 +0300 |
commit | 96667e33913e37e257ae444009c5f7bea57b0d72 (patch) | |
tree | 848e321c44e3e0ea2f6de1af14d3aa01c9dc0771 /source/blender/blenloader/intern | |
parent | 6c25aabddfb484980e87e2b1cb07e31350c61796 (diff) |
Fix T93058: Crash on opening old pre-2.80 .blend files.
Layer resync code would not yet fully properly deal with all possible
invalid status of ViewLayer comming from those older files.
Now put 2.80-doversion specific fixes into their own dedicated
function, so that they do not affect actual regular layer resync code
anymore. Also added some sanity-checks in main
`BKE_layer_collection_sync` code.
Diffstat (limited to 'source/blender/blenloader/intern')
-rw-r--r-- | source/blender/blenloader/intern/versioning_280.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c index d9052c6b1f7..ceddc451a46 100644 --- a/source/blender/blenloader/intern/versioning_280.c +++ b/source/blender/blenloader/intern/versioning_280.c @@ -402,6 +402,8 @@ static void do_version_scene_collection_to_collection(Main *bmain, Scene *scene) do_version_layer_collection_pre( view_layer, &view_layer->layer_collections, enabled_set, selectable_set); + BKE_layer_collection_doversion_2_80(scene, view_layer); + BKE_layer_collection_sync(scene, view_layer); do_version_layer_collection_post( |