summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTiziano Carotti <tizianoc@fastwebnet.it>2012-07-26 09:53:42 +0200
committerGiulio Cervera <giulio.cervera@gmail.com>2012-07-26 17:45:43 +0200
commit1ab9ebe5a6ccf6457ebdbfa55226e4b1c1c9c22c (patch)
tree3be6dff58e0feef3cd62798a647cbe511162e983
parent5d054a459c63b1f4bb77c1ea0d51f28f1e74d513 (diff)
downloadandroid_hardware_qcom_media-1ab9ebe5a6ccf6457ebdbfa55226e4b1c1c9c22c.tar.gz
android_hardware_qcom_media-1ab9ebe5a6ccf6457ebdbfa55226e4b1c1c9c22c.tar.bz2
android_hardware_qcom_media-1ab9ebe5a6ccf6457ebdbfa55226e4b1c1c9c22c.zip
audio/msm7x30: fix a crash on audio initialize
-Fixes crash on mediaserver if the device_count got from audioalsa library is greater than DEVICE_COUNT in HAL Change-Id: I802af5f976620502dfe4c0761b81ad42d6fde81d
-rw-r--r--audio/msm7x30/AudioHardware.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/audio/msm7x30/AudioHardware.cpp b/audio/msm7x30/AudioHardware.cpp
index 24d0a42a..801f57f9 100644
--- a/audio/msm7x30/AudioHardware.cpp
+++ b/audio/msm7x30/AudioHardware.cpp
@@ -582,7 +582,7 @@ AudioHardware::AudioHardware() :
LOGE("malloc failed for device list");
return;
}
- for(i = 0;i<dev_cnt;i++)
+ for(i = 0;i<DEVICE_COUNT;i++)
device_list[i].dev_id = INVALID_DEVICE;
for(i = 0; i < dev_cnt;i++) {