From: Tim Walker Date: Mon, 18 Nov 2013 11:41:47 +0000 (+0100) Subject: ac3dec: simplify an expression X-Git-Tag: v10_alpha1~219 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ffb0af7f17eb0da86e9b140e86a1404d3c6c9e79;p=platform%2Fupstream%2Flibav.git ac3dec: simplify an expression Signed-off-by: Diego Biurrun --- diff --git a/libavcodec/ac3dec.c b/libavcodec/ac3dec.c index 3edb3af..6419208 100644 --- a/libavcodec/ac3dec.c +++ b/libavcodec/ac3dec.c @@ -178,9 +178,8 @@ static av_cold int ac3_decode_init(AVCodecContext *avctx) avctx->sample_fmt = AV_SAMPLE_FMT_FLTP; /* allow downmixing to stereo or mono */ - if (avctx->channels > 0 && avctx->request_channels > 0 && - avctx->request_channels < avctx->channels && - avctx->request_channels <= 2) { + if (avctx->request_channels > 0 && avctx->request_channels <= 2 && + avctx->request_channels < avctx->channels) { avctx->channels = avctx->request_channels; } s->downmixed = 1;