forked from pool/alsa-utils
Takashi Iwai
8bad45cd50
- Build with libsamplerate for aloop (bnc#792173) - Add a patch to handle alsaloop properly without libsamplerate (bnc#792173): 0010-alsaloop-Make-alsaloop-working-without-libsamplerate.patch 0011-alsaloop-Fix-missing-endif.patch - Backport fixes from upstream 0006-alsamixer-fix-handling-of-removed-controls.patch 0007-aplay-Show-usage-if-no-parameter-is-passed.patch 0008-amixer-fix-rounding-of-relative-changes.patch 0009-amixer-Fix-parsing-container-TLV-entries.patch OBS-URL: https://build.opensuse.org/request/show/143675 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=66
36 lines
1005 B
Diff
36 lines
1005 B
Diff
From da1c24a24c699125aedc8d4f7c97d974b868dacf Mon Sep 17 00:00:00 2001
|
|
From: Clemens Ladisch <clemens@ladisch.de>
|
|
Date: Tue, 13 Nov 2012 21:54:20 +0100
|
|
Subject: [PATCH 8/9] amixer: fix rounding of relative changes
|
|
|
|
When doing control changes by a relative amount, amixer used the wrong
|
|
rounding direction, which would make it possible to stay at the same raw
|
|
value if the step was not big enough to reach the next value.
|
|
|
|
Reported-by: Honza Javorek <jan.javorek@gmail.com>
|
|
Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
|
|
---
|
|
amixer/amixer.c | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/amixer/amixer.c b/amixer/amixer.c
|
|
index a0a7387..48ed1b2 100644
|
|
--- a/amixer/amixer.c
|
|
+++ b/amixer/amixer.c
|
|
@@ -425,10 +425,10 @@ static int set_volume_simple(snd_mixer_elem_t *elem,
|
|
invalid = 1;
|
|
if (*p == '+') {
|
|
val = orig + val;
|
|
- correct = -1;
|
|
+ correct = 1;
|
|
} else {
|
|
val = orig - val;
|
|
- correct = 1;
|
|
+ correct = -1;
|
|
}
|
|
}
|
|
p++;
|
|
--
|
|
1.8.0.1
|
|
|