From: Ilkka Ollakka Date: Sun, 13 Jun 2010 20:20:28 +0000 (+0300) Subject: mp4: calculate stream duration sameway all around X-Git-Tag: 1.2.0-pre1~6199 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=6ade0ae9db8ba30ab14aca7f0a71b0d875a6b20e;p=vlc mp4: calculate stream duration sameway all around --- diff --git a/modules/mux/mp4.c b/modules/mux/mp4.c index 8fde903da3..8af05589ec 100644 --- a/modules/mux/mp4.c +++ b/modules/mux/mp4.c @@ -564,7 +564,7 @@ again: } /* update */ - p_stream->i_duration += p_data->i_length; + p_stream->i_duration = p_stream->i_last_dts - p_stream->i_dts_start + p_data->i_length; p_sys->i_pos += p_data->i_buffer; /* Save the DTS */