Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bc6c6c62 authored by chenxin20's avatar chenxin20
Browse files

audio: Modify conditions to reduce unnecessary lock waiting behavior.



Change-Id: Id6d9e97f30fae90edf34b4defb0a6dd2f9dd4ce0
Signed-off-by: default avatarchenxin20 <chenxin20@xiaomi.com>
parent f54eb9cb
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -332,8 +332,8 @@ public class AudioDeviceBroker {
            Log.v(TAG, "setCommunicationDevice, device: " + device + ", uid: " + uid);
        }

        synchronized (mDeviceStateLock) {
        if (device == null) {
            synchronized (mDeviceStateLock) {
                CommunicationRouteClient client = getCommunicationRouteClientForUid(uid);
                if (client == null) {
                    return false;