summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVittorio Giovara <vittorio.giovara@gmail.com>2014-11-11 17:40:06 +0100
committerVittorio Giovara <vittorio.giovara@gmail.com>2014-11-13 01:41:26 +0100
commit2ffb0598dbdb81c40650952aa9299fa02fa5e834 (patch)
tree76c9e4309a02e24fd389855e83c8835201b90d35
parent6abe7edabb7d57e82d7ea6312d30cf05d2192c5b (diff)
downloadffmpeg-streaming-2ffb0598dbdb81c40650952aa9299fa02fa5e834.zip
ffmpeg-streaming-2ffb0598dbdb81c40650952aa9299fa02fa5e834.tar.gz
mlpdec: check for negative index
CC: libav-stable@libav.org Bug-Id: CID 970924
-rw-r--r--libavcodec/mlpdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/mlpdec.c b/libavcodec/mlpdec.c
index 6baf4c1..624efc1 100644
--- a/libavcodec/mlpdec.c
+++ b/libavcodec/mlpdec.c
@@ -552,7 +552,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
ch_assign = av_get_channel_layout_channel_index(s->ch_layout,
channel);
}
- if (ch_assign > s->max_matrix_channel) {
+ if (ch_assign < 0 || ch_assign > s->max_matrix_channel) {
avpriv_request_sample(m->avctx,
"Assignment of matrix channel %d to invalid output channel %d",
ch, ch_assign);
OpenPOWER on IntegriCloud