HDMI: Guard mEarcLocalDevice.mEarcStatus with mLock
This fixes an error prone reported in udc-tv-dev cherry-pick. Test: atest HdmiCecAtomLoggingTest Bug: 287180347 Change-Id: I4a6b6e62e01d8ee2be17c5620cf926e9c9dd610e
This commit is contained in:
@@ -4689,7 +4689,9 @@ public class HdmiControlService extends SystemService {
|
||||
private int getEarcStatus() {
|
||||
assertRunOnServiceThread();
|
||||
if (mEarcLocalDevice != null) {
|
||||
return mEarcLocalDevice.mEarcStatus;
|
||||
synchronized (mLock) {
|
||||
return mEarcLocalDevice.mEarcStatus;
|
||||
}
|
||||
}
|
||||
return HDMI_EARC_STATUS_UNKNOWN;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user