From 3e9dea3f8cb9f6ee46781f3cb611a0a39d7811d3 Mon Sep 17 00:00:00 2001 From: Chris Bass Date: Thu, 15 Aug 2013 10:59:10 +0100 Subject: [PATCH] qtdemux: check denominator isn't zero before scaling duration. When gst_qtdemux_configure_stream sets fps_d, check that n_samples is non-zero before using it as a denominator to scale the stream duration. https://bugzilla.gnome.org/show_bug.cgi?id=706076 --- gst/isomp4/qtdemux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gst/isomp4/qtdemux.c b/gst/isomp4/qtdemux.c index 82f4efd368..4c7a90bbfe 100644 --- a/gst/isomp4/qtdemux.c +++ b/gst/isomp4/qtdemux.c @@ -5596,7 +5596,7 @@ gst_qtdemux_configure_stream (GstQTDemux * qtdemux, QtDemuxStream * stream) stream->fps_n = stream->timescale * factor; - if (stream->duration == 0) + if (stream->duration == 0 || stream->n_samples == 0) stream->fps_d = factor; else stream->fps_d =