summaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-09-23 14:13:43 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-09-23 14:19:13 +0200
commitef7e8efc6befaf02b0953dbbbeb2fc0648b7bb58 (patch)
tree8745e0f77494b16ad306c0cb273adbd755748e15 /libavformat
parent7bac6e5cf81b1f956f06d15546a376e32f4ea558 (diff)
parentce67f442be0f6c4a8794272873852e256b5b8ee4 (diff)
downloadffmpeg-streaming-ef7e8efc6befaf02b0953dbbbeb2fc0648b7bb58.zip
ffmpeg-streaming-ef7e8efc6befaf02b0953dbbbeb2fc0648b7bb58.tar.gz
Merge commit 'ce67f442be0f6c4a8794272873852e256b5b8ee4'
* commit 'ce67f442be0f6c4a8794272873852e256b5b8ee4': lavf: Avoid setting avg_frame_rate if delta_dts is negative Conflicts: libavformat/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/utils.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 48db0da..822b216 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -2978,7 +2978,8 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options)
double best_error = 0.01;
if (st->info->codec_info_duration >= INT64_MAX / st->time_base.num / 2||
- st->info->codec_info_duration_fields >= INT64_MAX / st->time_base.den)
+ st->info->codec_info_duration_fields >= INT64_MAX / st->time_base.den ||
+ st->info->codec_info_duration < 0)
continue;
av_reduce(&st->avg_frame_rate.num, &st->avg_frame_rate.den,
st->info->codec_info_duration_fields*(int64_t)st->time_base.den,
OpenPOWER on IntegriCloud