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-12-17 04:11:22 +0300
committerRichard Antalik <richardantalik@gmail.com>2020-12-17 04:19:34 +0300
commitd11b219d40d7c72156fd11c335fde27212997957 (patch)
treed1c3e20758ae379fc1bc483d79d116213bb260a3 /source/blender/sequencer/intern/sequencer.c
parent3a1d1aaa86d0d7cc6aaf0e6633d557bbcdd0b514 (diff)
Fix T83869: Crash when creating Sequencer in new scene
Crash on null dereference in `SEQ_timeline_boundbox()`. This function was generalized in rB9e4a4c2e996c to work on arbitrary `seqbase`. Fixed by refactoring `SEQ_timeline_boundbox()` functions to return default sane values if `seqbase` is `NULL` Reviewed By: HooglyBoogly Differential Revision: https://developer.blender.org/D9878
Diffstat (limited to 'source/blender/sequencer/intern/sequencer.c')
-rw-r--r--source/blender/sequencer/intern/sequencer.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/source/blender/sequencer/intern/sequencer.c b/source/blender/sequencer/intern/sequencer.c
index 82971a30c31..87b608ef141 100644
--- a/source/blender/sequencer/intern/sequencer.c
+++ b/source/blender/sequencer/intern/sequencer.c
@@ -327,6 +327,20 @@ void SEQ_tool_settings_fit_method_set(Scene *scene, eSeqImageFitMethod fit_metho
tool_settings->fit_method = fit_method;
}
+/**
+ * Get seqbase that is being viewed currently. This can be main seqbase or meta strip seqbase
+ *
+ * \param ed: sequence editor data
+ * \return pointer to active seqbase. returns NULL if ed is NULL
+ */
+ListBase *SEQ_active_seqbase_get(const Editing *ed)
+{
+ if (ed == NULL) {
+ return NULL;
+ }
+
+ return ed->seqbasep;
+}
/** \} */
/* -------------------------------------------------------------------- */