Fix ANR issue for SimSlotChangeReceiver
Bug: 179109464 Test: Manually tested Change-Id: Ibcb5eb57cdb5a238f9e49945fea3da20b2ffb2ab
This commit is contained in:
@@ -52,11 +52,10 @@ public class SimSlotChangeReceiver extends BroadcastReceiver {
|
|||||||
ThreadUtils.postOnBackgroundThread(
|
ThreadUtils.postOnBackgroundThread(
|
||||||
() -> {
|
() -> {
|
||||||
synchronized (mLock) {
|
synchronized (mLock) {
|
||||||
if (!shouldHandleSlotChange(context)) {
|
if (shouldHandleSlotChange(context)) {
|
||||||
return;
|
|
||||||
}
|
|
||||||
mSlotChangeHandler.onSlotsStatusChange(context.getApplicationContext());
|
mSlotChangeHandler.onSlotsStatusChange(context.getApplicationContext());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
ThreadUtils.postOnMainThread(pendingResult::finish);
|
ThreadUtils.postOnMainThread(pendingResult::finish);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user