[FFmpeg-cvslog] avformat/img2dec: try to read PROBE_BUF_MIN instead of just enough for .pix probing

Michael Niedermayer git at videolan.org
Sat Mar 29 00:49:18 CET 2014


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Mar 29 00:18:56 2014 +0100| [2cffdcbdd7f6e07b42a4d87f646e4e945ab99aa4] | committer: Michael Niedermayer

avformat/img2dec: try to read PROBE_BUF_MIN instead of just enough for .pix probing

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=2cffdcbdd7f6e07b42a4d87f646e4e945ab99aa4
---

 libavformat/img2dec.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavformat/img2dec.c b/libavformat/img2dec.c
index f6df41d..d491241 100644
--- a/libavformat/img2dec.c
+++ b/libavformat/img2dec.c
@@ -354,11 +354,11 @@ int ff_img_read_packet(AVFormatContext *s1, AVPacket *pkt)
         if (codec->codec_id == AV_CODEC_ID_NONE) {
             AVProbeData pd;
             AVInputFormat *ifmt;
-            uint8_t header[20 + AVPROBE_PADDING_SIZE];
+            uint8_t header[PROBE_BUF_MIN + AVPROBE_PADDING_SIZE];
             int ret;
             int score = 0;
 
-            ret = avio_read(f[0], header, 20);
+            ret = avio_read(f[0], header, PROBE_BUF_MIN);
             if (ret < 0)
                 return ret;
             avio_skip(f[0], -ret);



More information about the ffmpeg-cvslog mailing list