[FFmpeg-cvslog] avformat/utils: dont count attached pics toward the probesize
Michael Niedermayer
git at videolan.org
Mon Nov 18 15:19:34 CET 2013
ffmpeg | branch: release/1.1 | Michael Niedermayer <michaelni at gmx.at> | Mon Nov 18 03:02:36 2013 +0100| [f401e600638b389301be8c4bb0758c4f7a3086ab] | committer: Carl Eugen Hoyos
avformat/utils: dont count attached pics toward the probesize
Such pics behave more like headers which we also dont count.
Fixes Ticket3146
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
(cherry picked from commit a8dec360c5db15e8da4b44ff3c0f02a6c57e8ac0)
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f401e600638b389301be8c4bb0758c4f7a3086ab
---
libavformat/utils.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/libavformat/utils.c b/libavformat/utils.c
index aa0c103..1be62f1 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -2819,9 +2819,10 @@ int avformat_find_stream_info(AVFormatContext *ic, AVDictionary **options)
goto find_stream_info_err;
}
- read_size += pkt->size;
-
st = ic->streams[pkt->stream_index];
+ if (!(st->disposition & AV_DISPOSITION_ATTACHED_PIC))
+ read_size += pkt->size;
+
if (pkt->dts != AV_NOPTS_VALUE && st->codec_info_nb_frames > 1) {
/* check for non-increasing dts */
if (st->info->fps_last_dts != AV_NOPTS_VALUE &&
More information about the ffmpeg-cvslog
mailing list