From d2451882d21a3c792bf2e1b04ce25fc690aabe06 Mon Sep 17 00:00:00 2001 From: Jean-Michel Trivi Date: Fri, 15 Oct 2010 16:14:53 -0700 Subject: Contribute to fixing bug 3060335 Make Crespo honour voice rec mode Crespo libaudio fails to use the Voice Recognition configuration when doing a recording on the VOICE_RECOGNITION input because the associated setParameter always returns before the value is set due to a cast error. Change-Id: Icc7c7edb5f680de82140d6ece4e536c0d9cb2419 --- libaudio/AudioHardwareALSA.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libaudio/AudioHardwareALSA.cpp b/libaudio/AudioHardwareALSA.cpp index b05b979..ee896e0 100755 --- a/libaudio/AudioHardwareALSA.cpp +++ b/libaudio/AudioHardwareALSA.cpp @@ -2128,7 +2128,7 @@ status_t ALSAControl::set(const char *name, unsigned int value, int index) snd_ctl_elem_info_get_id(info, id); snd_ctl_elem_type_t type = snd_ctl_elem_info_get_type(info); unsigned int count = snd_ctl_elem_info_get_count(info); - if ((unsigned int)index >= count) return BAD_VALUE; + if (index >= (int)count) return BAD_VALUE; if (index == -1) index = 0; // Range over all of them -- cgit v1.1