OSDN Git Service
(root)
/
android-x86
/
frameworks-av.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aaa42e5
)
Fix race in AudioTrack::getParameters()
author
Glenn Kasten
<gkasten@google.com>
Mon, 13 Jan 2014 18:29:08 +0000
(10:29 -0800)
committer
Glenn Kasten
<gkasten@google.com>
Mon, 13 Jan 2014 19:48:33 +0000
(11:48 -0800)
mOutput is protected by mLock.
Change-Id: Id02e627062855ca60f28bd8961b1d5f44939c727
media/libmedia/AudioTrack.cpp
patch
|
blob
|
history
diff --git
a/media/libmedia/AudioTrack.cpp
b/media/libmedia/AudioTrack.cpp
index
a6ffc62
..
1d56788
100644
(file)
--- a/
media/libmedia/AudioTrack.cpp
+++ b/
media/libmedia/AudioTrack.cpp
@@
-1768,8
+1768,9
@@
status_t AudioTrack::getTimestamp(AudioTimestamp& timestamp)
String8 AudioTrack::getParameters(const String8& keys)
{
- if (mOutput) {
- return AudioSystem::getParameters(mOutput, keys);
+ audio_io_handle_t output = getOutput();
+ if (output != 0) {
+ return AudioSystem::getParameters(output, keys);
} else {
return String8::empty();
}