mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-02-09 14:14:39 +02:00
avformat/img2dec: try to read PROBE_BUF_MIN instead of just enough for .pix probing
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
1c13e1ef36
commit
2cffdcbdd7
@ -354,11 +354,11 @@ int ff_img_read_packet(AVFormatContext *s1, AVPacket *pkt)
|
|||||||
if (codec->codec_id == AV_CODEC_ID_NONE) {
|
if (codec->codec_id == AV_CODEC_ID_NONE) {
|
||||||
AVProbeData pd;
|
AVProbeData pd;
|
||||||
AVInputFormat *ifmt;
|
AVInputFormat *ifmt;
|
||||||
uint8_t header[20 + AVPROBE_PADDING_SIZE];
|
uint8_t header[PROBE_BUF_MIN + AVPROBE_PADDING_SIZE];
|
||||||
int ret;
|
int ret;
|
||||||
int score = 0;
|
int score = 0;
|
||||||
|
|
||||||
ret = avio_read(f[0], header, 20);
|
ret = avio_read(f[0], header, PROBE_BUF_MIN);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
return ret;
|
return ret;
|
||||||
avio_skip(f[0], -ret);
|
avio_skip(f[0], -ret);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user