OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4f1a787
)
adxdec: Validate channel count to fix a division by zero.
author
Justin Ruggles
<justin.ruggles@gmail.com>
Mon, 19 Dec 2011 13:43:10 +0000
(08:43 -0500)
committer
Justin Ruggles
<justin.ruggles@gmail.com>
Tue, 3 Jan 2012 21:28:17 +0000
(16:28 -0500)
libavcodec/adx.c
patch
|
blob
|
history
diff --git
a/libavcodec/adx.c
b/libavcodec/adx.c
index
aa90fd8
..
1e5d89c
100644
(file)
--- a/
libavcodec/adx.c
+++ b/
libavcodec/adx.c
@@
-58,7
+58,7
@@
int avpriv_adx_decode_header(AVCodecContext *avctx, const uint8_t *buf,
/* channels */
avctx->channels = buf[7];
- if (avctx->channels > 2)
+ if (avctx->channels
<= 0 || avctx->channels
> 2)
return AVERROR_INVALIDDATA;
/* sample rate */