summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorPraveen Chavan <pchavan@codeaurora.org>2015-09-29 02:25:47 -0700
committerGlenn Kasten <gkasten@google.com>2015-10-05 09:13:59 -0700
commit4802c0c507681634aee38518581a080bfa443ae2 (patch)
treee184ee110c468c7ef4621e5e32a6b8bfeaab11d6 /include
parent4a8f4a3f567d8b3134b1c7ab21ca774f279ab9c2 (diff)
downloadframeworks_av-4802c0c507681634aee38518581a080bfa443ae2.zip
frameworks_av-4802c0c507681634aee38518581a080bfa443ae2.tar.gz
frameworks_av-4802c0c507681634aee38518581a080bfa443ae2.tar.bz2
AudioSystem: Fix race condition in accessing ioDescriptors
The vector mIoDescriptors can be simultaneouly modified and accessed by 2 threads. Acquire a lock while wrapping the ioDescriptor in a sp<> Bug: 24576810 Author: Haynes Mathew George <hgeorge@codeaurora.org> Change-Id: I73c79ef8eca092b500a7ead3a5ebd0bcf75f9920
Diffstat (limited to 'include')
-rw-r--r--include/media/AudioSystem.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/media/AudioSystem.h b/include/media/AudioSystem.h
index 06116a5..26a0bb2 100644
--- a/include/media/AudioSystem.h
+++ b/include/media/AudioSystem.h
@@ -399,6 +399,7 @@ private:
uint32_t mInSamplingRate;
audio_format_t mInFormat;
audio_channel_mask_t mInChannelMask;
+ sp<AudioIoDescriptor> getIoDescriptor_l(audio_io_handle_t ioHandle);
};
class AudioPolicyServiceClient: public IBinder::DeathRecipient,