Fix T47862: VSE hard cut fails

Regression caused by changing how video length is calculated,
however similar problems could be caused by strip length changing on-disk.
This commit is contained in:
Campbell Barton 2016-03-21 19:22:39 +11:00
parent f4840e878b
commit 112300a982

@ -685,6 +685,14 @@ static Sequence *cut_seq_hard(Scene *scene, Sequence *seq, int cutframe)
/* First Strip! */
/* strips with extended stillfames before */
/* Precaution, needed because the length saved on-disk may not match the length saved in the blend file,
* or our code may have minor differences reading file length between versions.
* This causes hard-cut to fail, see: T47862 */
if (seq->type != SEQ_TYPE_META) {
BKE_sequence_reload_new_file(scene, seq, true);
BKE_sequence_calc(scene, seq);
}
if ((seq->startstill) && (cutframe < seq->start)) {
/* don't do funny things with METAs ... */
if (seq->type == SEQ_TYPE_META) {