From: Mike Brady Date: Wed, 27 Apr 2016 08:23:15 +0000 (+0200) Subject: If the volume is out of range 0 -- -30 or -144, return minimum vol X-Git-Tag: 2.8.3.2~11 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d02bb0e336e1df88058ad55e61834973b9adc4fd;p=thirdparty%2Fshairport-sync.git If the volume is out of range 0 -- -30 or -144, return minimum vol --- diff --git a/common.c b/common.c index bc077732..a86fd8e2 100644 --- a/common.c +++ b/common.c @@ -465,6 +465,7 @@ double vol2attn(double vol, long max_db, long min_db) { } else if (vol != -144.0) { debug(1, "Volume request value %f is out of range: should be from 0.0 to -30.0 or -144.0.", vol); + vol_setting = min_db; // for safety, return the lowest setting... } else { vol_setting = min_db; // for safety, return the lowest setting... }