av_find_stream_info: Print more details about max anaylize duration failures.
authorMichael Niedermayer <michaelni@gmx.at>
Wed, 18 May 2011 19:39:22 +0000 (21:39 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Thu, 19 May 2011 01:45:00 +0000 (03:45 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/utils.c

index 70429a7..3509620 100644 (file)
@@ -2327,8 +2327,9 @@ int av_find_stream_info(AVFormatContext *ic)
 
         st = ic->streams[pkt->stream_index];
         if (st->codec_info_nb_frames>1) {
-            if (st->time_base.den > 0 && av_rescale_q(st->info->codec_info_duration, st->time_base, AV_TIME_BASE_Q) >= ic->max_analyze_duration) {
-                av_log(ic, AV_LOG_WARNING, "max_analyze_duration reached\n");
+            int64_t t;
+            if (st->time_base.den > 0 && (t=av_rescale_q(st->info->codec_info_duration, st->time_base, AV_TIME_BASE_Q)) >= ic->max_analyze_duration) {
+                av_log(ic, AV_LOG_WARNING, "max_analyze_duration %d reached at %Ld\n", ic->max_analyze_duration, t);
                 break;
             }
             st->info->codec_info_duration += pkt->duration;