From: Jaroslav Kysela Date: Mon, 11 Aug 2003 09:42:16 +0000 (+0000) Subject: Use float to avoid overflow X-Git-Tag: v1.0.3~51 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=340b2ca3c992261e4b989e7964842ad83d0acfe2;p=alsa-utils.git Use float to avoid overflow --- diff --git a/alsamixer/alsamixer.c b/alsamixer/alsamixer.c index 3708a28..47436cf 100644 --- a/alsamixer/alsamixer.c +++ b/alsamixer/alsamixer.c @@ -468,7 +468,7 @@ mixer_cbar_get_pos (int elem_index, static int mixer_conv(int val, int omin, int omax, int nmin, int nmax) { - int orange = omax - omin, nrange = nmax - nmin; + float orange = omax - omin, nrange = nmax - nmin; if (orange == 0) return 0;