From: RĂ©mi Denis-Courmont Date: Thu, 2 Oct 2014 18:39:35 +0000 (+0300) Subject: avformat: fix signed overflow X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;ds=inline;h=8ac5cc821f0a976c32885d56d33d2e358f776414;p=vlc avformat: fix signed overflow --- diff --git a/modules/demux/avformat/demux.c b/modules/demux/avformat/demux.c index 6cffad3b6d..da7d4c1679 100644 --- a/modules/demux/avformat/demux.c +++ b/modules/demux/avformat/demux.c @@ -757,7 +757,7 @@ static int Demux( demux_t *p_demux ) p_stream->time_base.den - i_start_time + VLC_TS_0; } if( pkt.duration > 0 && p_frame->i_length <= 0 ) - p_frame->i_length = pkt.duration * 1000000 * + p_frame->i_length = pkt.duration * INT64_C(1000000) * p_stream->time_base.num / p_stream->time_base.den;