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>2021-11-18 03:05:51 +0300
committerRichard Antalik <richardantalik@gmail.com>2021-11-18 03:11:51 +0300
commitb071083496638e7e96b787f524a5b9add094010d (patch)
tree64add936182b2d13de17cbb561e3c98a516c55c4 /source/blender/sequencer/intern/render.c
parent00a9617f92fdae6c847575d10fac8a66e8322257 (diff)
Fix T93166: Division by zero when drawing thumbnails
Caused by incorrect step calculation fo too short strips. For these, step should be equal to strip length not 0.
Diffstat (limited to 'source/blender/sequencer/intern/render.c')
-rw-r--r--source/blender/sequencer/intern/render.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/sequencer/intern/render.c b/source/blender/sequencer/intern/render.c
index 12d97d7e3e3..8ce3398024d 100644
--- a/source/blender/sequencer/intern/render.c
+++ b/source/blender/sequencer/intern/render.c
@@ -2047,7 +2047,7 @@ int SEQ_render_thumbnails_guaranteed_set_frame_step_get(const Sequence *seq)
/* Arbitrary, but due to performance reasons should be as low as possible. */
const int thumbnails_base_set_count = min_ii(content_len / 100, 30);
if (thumbnails_base_set_count <= 0) {
- return 0;
+ return content_len;
}
return content_len / thumbnails_base_set_count;
}