Merge "Fix NPE in AppOpsService." into rvc-dev

This commit is contained in:
TreeHugger Robot
2020-06-22 22:14:52 +00:00
committed by Android (Google) Code Review

View File

@@ -3744,7 +3744,7 @@ public class AppOpsService extends IAppOpsService.Stub {
mHandler.sendMessage(PooledLambda.obtainMessage(
AppOpsService::notifyOpChangedForAllPkgsInUid,
this, code, uidState.uid, true, null));
} else {
} else if (uidState.pkgOps != null) {
final ArraySet<ModeCallback> callbacks = mOpModeWatchers.get(code);
if (callbacks != null) {
for (int cbi = callbacks.size() - 1; cbi >= 0; cbi--) {