aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/dump.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavformat/dump.c')
-rw-r--r--libavformat/dump.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/dump.c b/libavformat/dump.c
index 705da82148..08b86935e4 100644
--- a/libavformat/dump.c
+++ b/libavformat/dump.c
@@ -496,7 +496,7 @@ void av_dump_format(AVFormatContext *ic, int index,
av_log(NULL, AV_LOG_INFO, " Duration: ");
if (ic->duration != AV_NOPTS_VALUE) {
int hours, mins, secs, us;
- int64_t duration = ic->duration + 5000;
+ int64_t duration = ic->duration + (ic->duration <= INT64_MAX - 5000 ? 5000 : 0);
secs = duration / AV_TIME_BASE;
us = duration % AV_TIME_BASE;
mins = secs / 60;