Loading media/libaaudio/src/client/AudioStreamInternal.cpp +11 −5 Original line number Diff line number Diff line Loading @@ -392,19 +392,25 @@ aaudio_result_t AudioStreamInternal::unregisterThread() { } aaudio_result_t AudioStreamInternal::startClient(const android::AudioClient& client, audio_port_handle_t *clientHandle) { audio_port_handle_t *portHandle) { ALOGV("%s() called", __func__); if (mServiceStreamHandle == AAUDIO_HANDLE_INVALID) { return AAUDIO_ERROR_INVALID_STATE; } return mServiceInterface.startClient(mServiceStreamHandle, client, clientHandle); aaudio_result_t result = mServiceInterface.startClient(mServiceStreamHandle, client, portHandle); ALOGV("%s(%d) returning %d", __func__, *portHandle, result); return result; } aaudio_result_t AudioStreamInternal::stopClient(audio_port_handle_t clientHandle) { aaudio_result_t AudioStreamInternal::stopClient(audio_port_handle_t portHandle) { ALOGV("%s(%d) called", __func__, portHandle); if (mServiceStreamHandle == AAUDIO_HANDLE_INVALID) { return AAUDIO_ERROR_INVALID_STATE; } return mServiceInterface.stopClient(mServiceStreamHandle, clientHandle); aaudio_result_t result = mServiceInterface.stopClient(mServiceStreamHandle, portHandle); ALOGV("%s(%d) returning %d", __func__, portHandle, result); return result; } aaudio_result_t AudioStreamInternal::getTimestamp(clockid_t clockId, Loading services/audioflinger/BufLog.cpp +2 −1 Original line number Diff line number Diff line Loading @@ -24,6 +24,7 @@ #include <pthread.h> #include <stdio.h> #include <string.h> #include <audio_utils/string.h> #define MIN(a, b) ((a) < (b) ? (a) : (b)) Loading Loading @@ -117,7 +118,7 @@ BufLogStream::BufLogStream(unsigned int id, mByteCount = 0l; mPaused = false; if (tag != NULL) { strncpy(mTag, tag, BUFLOGSTREAM_MAX_TAGSIZE); (void)audio_utils_strlcpy(mTag, tag); } else { mTag[0] = 0; } Loading services/audiopolicy/common/managerdefinitions/Android.mk +1 −0 Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ LOCAL_C_INCLUDES := \ frameworks/av/services/audiopolicy/common/include \ frameworks/av/services/audiopolicy \ frameworks/av/services/audiopolicy/utilities \ system/media/audio_utils/include \ ifeq ($(USE_XML_AUDIO_POLICY_CONF), 1) Loading services/audiopolicy/common/managerdefinitions/src/DeviceDescriptor.cpp +3 −2 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ #define LOG_TAG "APM::Devices" //#define LOG_NDEBUG 0 #include <audio_utils/string.h> #include "DeviceDescriptor.h" #include "TypeConverter.h" #include "AudioGain.h" Loading Loading @@ -247,7 +248,7 @@ void DeviceDescriptor::toAudioPortConfig(struct audio_port_config *dstConfig, // ALOG_ASSERT(mModule != NULL); dstConfig->ext.device.hw_module = mModule != 0 ? mModule->getHandle() : AUDIO_MODULE_HANDLE_NONE; strncpy(dstConfig->ext.device.address, mAddress.string(), AUDIO_DEVICE_MAX_ADDRESS_LEN); (void)audio_utils_strlcpy_zerofill(dstConfig->ext.device.address, mAddress.string()); } void DeviceDescriptor::toAudioPort(struct audio_port *port) const Loading @@ -258,7 +259,7 @@ void DeviceDescriptor::toAudioPort(struct audio_port *port) const toAudioPortConfig(&port->active_config); port->ext.device.type = mDeviceType; port->ext.device.hw_module = mModule->getHandle(); strncpy(port->ext.device.address, mAddress.string(), AUDIO_DEVICE_MAX_ADDRESS_LEN); (void)audio_utils_strlcpy_zerofill(port->ext.device.address, mAddress.string()); } void DeviceDescriptor::importAudioPort(const sp<AudioPort>& port, bool force) { Loading services/camera/libcameraservice/CameraService.cpp +2 −0 Original line number Diff line number Diff line Loading @@ -243,6 +243,7 @@ void CameraService::addStates(const String8 id) { } if (mFlashlight->hasFlashUnit(id)) { Mutex::Autolock al(mTorchStatusMutex); mTorchStatusMap.add(id, TorchModeStatus::AVAILABLE_OFF); } Loading @@ -253,6 +254,7 @@ void CameraService::addStates(const String8 id) { void CameraService::removeStates(const String8 id) { updateCameraNumAndIds(); if (mFlashlight->hasFlashUnit(id)) { Mutex::Autolock al(mTorchStatusMutex); mTorchStatusMap.removeItem(id); } Loading Loading
media/libaaudio/src/client/AudioStreamInternal.cpp +11 −5 Original line number Diff line number Diff line Loading @@ -392,19 +392,25 @@ aaudio_result_t AudioStreamInternal::unregisterThread() { } aaudio_result_t AudioStreamInternal::startClient(const android::AudioClient& client, audio_port_handle_t *clientHandle) { audio_port_handle_t *portHandle) { ALOGV("%s() called", __func__); if (mServiceStreamHandle == AAUDIO_HANDLE_INVALID) { return AAUDIO_ERROR_INVALID_STATE; } return mServiceInterface.startClient(mServiceStreamHandle, client, clientHandle); aaudio_result_t result = mServiceInterface.startClient(mServiceStreamHandle, client, portHandle); ALOGV("%s(%d) returning %d", __func__, *portHandle, result); return result; } aaudio_result_t AudioStreamInternal::stopClient(audio_port_handle_t clientHandle) { aaudio_result_t AudioStreamInternal::stopClient(audio_port_handle_t portHandle) { ALOGV("%s(%d) called", __func__, portHandle); if (mServiceStreamHandle == AAUDIO_HANDLE_INVALID) { return AAUDIO_ERROR_INVALID_STATE; } return mServiceInterface.stopClient(mServiceStreamHandle, clientHandle); aaudio_result_t result = mServiceInterface.stopClient(mServiceStreamHandle, portHandle); ALOGV("%s(%d) returning %d", __func__, portHandle, result); return result; } aaudio_result_t AudioStreamInternal::getTimestamp(clockid_t clockId, Loading
services/audioflinger/BufLog.cpp +2 −1 Original line number Diff line number Diff line Loading @@ -24,6 +24,7 @@ #include <pthread.h> #include <stdio.h> #include <string.h> #include <audio_utils/string.h> #define MIN(a, b) ((a) < (b) ? (a) : (b)) Loading Loading @@ -117,7 +118,7 @@ BufLogStream::BufLogStream(unsigned int id, mByteCount = 0l; mPaused = false; if (tag != NULL) { strncpy(mTag, tag, BUFLOGSTREAM_MAX_TAGSIZE); (void)audio_utils_strlcpy(mTag, tag); } else { mTag[0] = 0; } Loading
services/audiopolicy/common/managerdefinitions/Android.mk +1 −0 Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ LOCAL_C_INCLUDES := \ frameworks/av/services/audiopolicy/common/include \ frameworks/av/services/audiopolicy \ frameworks/av/services/audiopolicy/utilities \ system/media/audio_utils/include \ ifeq ($(USE_XML_AUDIO_POLICY_CONF), 1) Loading
services/audiopolicy/common/managerdefinitions/src/DeviceDescriptor.cpp +3 −2 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ #define LOG_TAG "APM::Devices" //#define LOG_NDEBUG 0 #include <audio_utils/string.h> #include "DeviceDescriptor.h" #include "TypeConverter.h" #include "AudioGain.h" Loading Loading @@ -247,7 +248,7 @@ void DeviceDescriptor::toAudioPortConfig(struct audio_port_config *dstConfig, // ALOG_ASSERT(mModule != NULL); dstConfig->ext.device.hw_module = mModule != 0 ? mModule->getHandle() : AUDIO_MODULE_HANDLE_NONE; strncpy(dstConfig->ext.device.address, mAddress.string(), AUDIO_DEVICE_MAX_ADDRESS_LEN); (void)audio_utils_strlcpy_zerofill(dstConfig->ext.device.address, mAddress.string()); } void DeviceDescriptor::toAudioPort(struct audio_port *port) const Loading @@ -258,7 +259,7 @@ void DeviceDescriptor::toAudioPort(struct audio_port *port) const toAudioPortConfig(&port->active_config); port->ext.device.type = mDeviceType; port->ext.device.hw_module = mModule->getHandle(); strncpy(port->ext.device.address, mAddress.string(), AUDIO_DEVICE_MAX_ADDRESS_LEN); (void)audio_utils_strlcpy_zerofill(port->ext.device.address, mAddress.string()); } void DeviceDescriptor::importAudioPort(const sp<AudioPort>& port, bool force) { Loading
services/camera/libcameraservice/CameraService.cpp +2 −0 Original line number Diff line number Diff line Loading @@ -243,6 +243,7 @@ void CameraService::addStates(const String8 id) { } if (mFlashlight->hasFlashUnit(id)) { Mutex::Autolock al(mTorchStatusMutex); mTorchStatusMap.add(id, TorchModeStatus::AVAILABLE_OFF); } Loading @@ -253,6 +254,7 @@ void CameraService::addStates(const String8 id) { void CameraService::removeStates(const String8 id) { updateCameraNumAndIds(); if (mFlashlight->hasFlashUnit(id)) { Mutex::Autolock al(mTorchStatusMutex); mTorchStatusMap.removeItem(id); } Loading