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:
authorRichard Antalik <richardantalik@gmail.com>2020-04-27 00:35:56 +0300
committerRichard Antalik <richardantalik@gmail.com>2020-04-27 00:40:18 +0300
commitdea1c1b9eb4378bcf4d2f097f3b90a90076f8edd (patch)
tree1327935f5dfe16862d412b19be1f3e97b927bec3 /source/blender/blenkernel/intern/sequencer.c
parent05b94c9c5457ac119f52fa9db6e41a218b64c477 (diff)
Fix T75495: Blender crashes opening a VSE .blend file
During scene copy modifier mask strips are relinked to point to strips in new scene. If strip used as mask is in different seqbase, this can fail, if seqbase is not copied yet. Add SEQ_DUPE_IS_RECURSIVE_CALL flag to avoid relinking modifiers during recursive call. Reviewed By: brecht Differential Revision: https://developer.blender.org/D7412
Diffstat (limited to 'source/blender/blenkernel/intern/sequencer.c')
-rw-r--r--source/blender/blenkernel/intern/sequencer.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/sequencer.c b/source/blender/blenkernel/intern/sequencer.c
index 93e5a3bbd74..d3d885fccd9 100644
--- a/source/blender/blenkernel/intern/sequencer.c
+++ b/source/blender/blenkernel/intern/sequencer.c
@@ -5818,7 +5818,7 @@ void BKE_sequence_base_dupli_recursive(const Scene *scene_src,
Sequence *seqn = NULL;
Sequence *last_seq = BKE_sequencer_active_get((Scene *)scene_src);
/* always include meta's strips */
- int dupe_flag_recursive = dupe_flag | SEQ_DUPE_ALL;
+ int dupe_flag_recursive = dupe_flag | SEQ_DUPE_ALL | SEQ_DUPE_IS_RECURSIVE_CALL;
for (seq = seqbase->first; seq; seq = seq->next) {
seq->tmp = NULL;
@@ -5844,6 +5844,12 @@ void BKE_sequence_base_dupli_recursive(const Scene *scene_src,
}
}
+ /* Fix modifier links recursively from the top level only, when all sequences have been
+ * copied. */
+ if (dupe_flag & SEQ_DUPE_IS_RECURSIVE_CALL) {
+ return;
+ }
+
/* fix modifier linking */
for (seq = nseqbase->first; seq; seq = seq->next) {
seq_new_fix_links_recursive(seq);