From 640d01319b1ba630c1d279295102f72665abafe5 Mon Sep 17 00:00:00 2001 From: Jaroslav Kysela Date: Fri, 5 Jun 2020 17:59:31 +0200 Subject: [PATCH] amixer: retype to double in convert_prange1() like in convert_prange() Signed-off-by: Jaroslav Kysela --- amixer/amixer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/amixer/amixer.c b/amixer/amixer.c index 7f1bb3b..b3b9b48 100644 --- a/amixer/amixer.c +++ b/amixer/amixer.c @@ -203,7 +203,7 @@ static long convert_prange1(long perc, long min, long max) { long tmp; - tmp = rint(perc * (max - min) * 0.01); + tmp = rint((double)perc * (double)(max - min) * 0.01); if (tmp == 0 && perc > 0) tmp++; return tmp + min;