diff options
author | Paul B Mahol <onemda@gmail.com> | 2020-09-16 15:20:21 +0200 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2020-09-16 15:22:54 +0200 |
commit | 161495a3d026a73bc802c66a94e867ef457320d4 (patch) | |
tree | eff6759d25720162f4318cdbdf4c41400c3fd95f /libavcodec/pngdec.c | |
parent | c79f07cc0c0b15252f13f56d61cf29c0081445b3 (diff) |
avcodec/lscr: stop returning error if size of packet is 2 bytes
Diffstat (limited to 'libavcodec/pngdec.c')
-rw-r--r-- | libavcodec/pngdec.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/pngdec.c b/libavcodec/pngdec.c index 647e7f0a74..395b86bbe7 100644 --- a/libavcodec/pngdec.c +++ b/libavcodec/pngdec.c @@ -1597,6 +1597,8 @@ static int decode_frame_lscr(AVCodecContext *avctx, if (avpkt->size < 2) return AVERROR_INVALIDDATA; + if (avpkt->size == 2) + return 0; bytestream2_init(gb, avpkt->data, avpkt->size); |