projects
/
platform
/
upstream
/
libav.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a9f108b
)
imc: add required padding for GetBitContext buffer
author
Janne Grunau
<janne-libav@jannau.net>
Mon, 8 Jun 2015 12:48:54 +0000
(14:48 +0200)
committer
Janne Grunau
<janne-libav@jannau.net>
Wed, 8 Jul 2015 21:37:51 +0000
(23:37 +0200)
Fixes stack buffer overflow errors detected by address sanitizer in
fate-imc.
CC: libav-stable@libav.org
libavcodec/imc.c
patch
|
blob
|
history
diff --git
a/libavcodec/imc.c
b/libavcodec/imc.c
index
500f564
..
26fbcd4
100644
(file)
--- a/
libavcodec/imc.c
+++ b/
libavcodec/imc.c
@@
-997,7
+997,7
@@
static int imc_decode_frame(AVCodecContext *avctx, void *data,
IMCContext *q = avctx->priv_data;
- LOCAL_ALIGNED_16(uint16_t, buf16, [
IMC_BLOCK_SIZE
/ 2]);
+ LOCAL_ALIGNED_16(uint16_t, buf16, [
(IMC_BLOCK_SIZE + FF_INPUT_BUFFER_PADDING_SIZE)
/ 2]);
if (buf_size < IMC_BLOCK_SIZE * avctx->channels) {
av_log(avctx, AV_LOG_ERROR, "frame too small!\n");