projects
/
libav.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
664eb77
)
cin audio: validate the channel count
author
Justin Ruggles
<justin.ruggles@gmail.com>
Thu, 27 Oct 2011 17:33:57 +0000
(13:33 -0400)
committer
Justin Ruggles
<justin.ruggles@gmail.com>
Sat, 29 Oct 2011 20:43:40 +0000
(16:43 -0400)
libavcodec/dsicinav.c
patch
|
blob
|
blame
|
history
diff --git
a/libavcodec/dsicinav.c
b/libavcodec/dsicinav.c
index
953d232
..
832efab
100644
(file)
--- a/
libavcodec/dsicinav.c
+++ b/
libavcodec/dsicinav.c
@@
-307,6
+307,11
@@
static av_cold int cinaudio_decode_init(AVCodecContext *avctx)
{
CinAudioContext *cin = avctx->priv_data;
+ if (avctx->channels != 1) {
+ av_log_ask_for_sample(avctx, "Number of channels is not supported\n");
+ return AVERROR_PATCHWELCOME;
+ }
+
cin->initial_decode_frame = 1;
cin->delta = 0;
avctx->sample_fmt = AV_SAMPLE_FMT_S16;