From 14f01bd39866b9d704c7ea69f6b4c45e1350a843 Mon Sep 17 00:00:00 2001 From: wm4 Date: Wed, 18 Oct 2017 12:11:37 +0200 Subject: aframe: fix logically dead code Detected by a well known static analyzer. --- audio/aframe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'audio') diff --git a/audio/aframe.c b/audio/aframe.c index 0a8ec38c93..1f053a6715 100644 --- a/audio/aframe.c +++ b/audio/aframe.c @@ -297,7 +297,7 @@ bool mp_aframe_set_chmap(struct mp_aframe *frame, struct mp_chmap *in) bool mp_aframe_set_rate(struct mp_aframe *frame, int rate) { - if (rate < 1 && rate > 10000000) + if (rate < 1 || rate > 10000000) return false; frame->av_frame->sample_rate = rate; return true; -- cgit v1.2.3