mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-25 01:30:38 +00:00
jpegdec: fix warning for still images by not trying to divide by 0
Don't pass a 0 divisor to gst_util_uint64_scale(), or it will complain in the single image case where fps=0/1 (are we supposed to differentiate between no fps=still image and fps=0/1=variable rate here btw?)
This commit is contained in:
parent
a097571c0a
commit
8d8e9af0a8
1 changed files with 1 additions and 1 deletions
|
@ -985,7 +985,7 @@ gst_jpeg_dec_chain (GstPad * pad, GstBuffer * buf)
|
|||
|
||||
/* calculate or assume an average frame duration for QoS purposes */
|
||||
GST_OBJECT_LOCK (dec);
|
||||
if (dec->framerate_denominator != 0) {
|
||||
if (dec->framerate_numerator != 0) {
|
||||
dec->qos_duration = gst_util_uint64_scale (GST_SECOND,
|
||||
dec->framerate_denominator, dec->framerate_numerator);
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue