summaryrefslogtreecommitdiffstats
path: root/libaudio
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2010-10-11 09:58:05 -0700
committerEric Laurent <elaurent@google.com>2010-10-11 09:58:05 -0700
commitf9491483bcceb94dc6ca493e06546cb5e2cadb36 (patch)
tree1cc81c432848176225e4651afadedcb2d8d08fd7 /libaudio
parent21c3eb4f7914e058403936f84ea2d1957e627237 (diff)
downloaddevice_samsung_crespo-f9491483bcceb94dc6ca493e06546cb5e2cadb36.zip
device_samsung_crespo-f9491483bcceb94dc6ca493e06546cb5e2cadb36.tar.gz
device_samsung_crespo-f9491483bcceb94dc6ca493e06546cb5e2cadb36.tar.bz2
Fix audio record broken
Audio input stream can not be opened because function snd_pcm_hw_params_get_period_size() now returns an error. Probably due to one of the recent kernel commits. The result of this call was not used anyway with current patch so removed it. Change-Id: I36f2dbdc94e6ec726d9c0df063d0ec3702c1b94a
Diffstat (limited to 'libaudio')
-rwxr-xr-xlibaudio/AudioHardwareALSA.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/libaudio/AudioHardwareALSA.cpp b/libaudio/AudioHardwareALSA.cpp
index 98ad027..b3d05d2 100755
--- a/libaudio/AudioHardwareALSA.cpp
+++ b/libaudio/AudioHardwareALSA.cpp
@@ -1156,6 +1156,7 @@ status_t ALSAStreamOps::setDevice(int mode, uint32_t device, uint audio_mode)
return NO_INIT;
}
+
//
// Some devices do not have the default two channels. Force an error to
// prevent AudioMixer from crashing and taking the whole system down.
@@ -1202,11 +1203,11 @@ status_t ALSAStreamOps::setDevice(int mode, uint32_t device, uint audio_mode)
return NO_INIT;
}
}
- err = snd_pcm_hw_params_get_period_size (mHardwareParams, &periodSize, NULL);
- if (err < 0) {
- LOGE("Unable to get the period size for latency: %s", snd_strerror(err));
- return NO_INIT;
- }
+// err = snd_pcm_hw_params_get_period_size (mHardwareParams, &periodSize, NULL);
+// if (err < 0) {
+// LOGE("Unable to get the period size for latency: %s", snd_strerror(err));
+// return NO_INIT;
+// }
// // Setup buffers for latency
// err = snd_pcm_hw_params_set_buffer_time_near (mHandle, mHardwareParams,