diff options
author | Anton Khirnov <anton@khirnov.net> | 2013-08-24 21:30:46 +0200 |
---|---|---|
committer | Luca Barbato <lu_zero@gentoo.org> | 2013-09-07 10:14:30 +0200 |
commit | 1e9d234c0c62cdce17016a68c948e4f4a8aceea3 (patch) | |
tree | b871ee62cb824a58001e5c3e07aac5485c14d1a7 | |
parent | 8dc4b2c92e492aa172327d10c926d5ca3a04371c (diff) | |
download | ffmpeg-1e9d234c0c62cdce17016a68c948e4f4a8aceea3.tar.gz |
pictordec: pass correct context to avpriv_request_sample
Fixes invalid reads.
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
(cherry-picked from commit fe9bb61f9a16be19ad91875632c39e44b7a99a8a)
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
-rw-r--r-- | libavcodec/pictordec.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/pictordec.c b/libavcodec/pictordec.c index f88fc52f1b..53fef1c6f6 100644 --- a/libavcodec/pictordec.c +++ b/libavcodec/pictordec.c @@ -122,7 +122,7 @@ static int decode_frame(AVCodecContext *avctx, s->nb_planes = (tmp >> 4) + 1; bpp = bits_per_plane * s->nb_planes; if (bits_per_plane > 8 || bpp < 1 || bpp > 32) { - av_log_ask_for_sample(s, "unsupported bit depth\n"); + av_log_ask_for_sample(avctx, "unsupported bit depth\n"); return AVERROR_PATCHWELCOME; } @@ -234,7 +234,7 @@ static int decode_frame(AVCodecContext *avctx, } } } else { - av_log_ask_for_sample(s, "uncompressed image\n"); + av_log_ask_for_sample(avctx, "uncompressed image\n"); return avpkt->size; } finish: |