Merge "Fix monkey bug 2586534 java.util.ConcurrentModificationException Unlike the other audio focus and media button stack handling methods, abandonAudioFocus() and unregisterAudioFocusClient() were not synchronized around their focus stack. This CL corrects this." into froyo
This commit is contained in:
committed by
Android (Google) Code Review
commit
12221b6f7c
@@ -2090,14 +2090,18 @@ public class AudioService extends IAudioService.Stub {
|
||||
Log.i(TAG, " AudioFocus abandonAudioFocus() from " + clientId);
|
||||
|
||||
// this will take care of notifying the new focus owner if needed
|
||||
removeFocusStackEntry(clientId, true);
|
||||
synchronized(mFocusStack) {
|
||||
removeFocusStackEntry(clientId, true);
|
||||
}
|
||||
|
||||
return AudioManager.AUDIOFOCUS_REQUEST_GRANTED;
|
||||
}
|
||||
|
||||
|
||||
public void unregisterAudioFocusClient(String clientId) {
|
||||
removeFocusStackEntry(clientId, false);
|
||||
synchronized(mFocusStack) {
|
||||
removeFocusStackEntry(clientId, false);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user