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

Commit 44b9032e authored by Hai Zhang's avatar Hai Zhang
Browse files

Fix crash when broadcasting preferred activity changed before boot completed.

By adding Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT.

Bug: 129269764
Test: presubmit
Change-Id: I2b57e2deee919ead768141f74508088a652d1415
parent 42dd2ded
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -20013,6 +20013,7 @@ public class PackageManagerService extends IPackageManager.Stub
            final Intent intent = new Intent(Intent.ACTION_PREFERRED_ACTIVITY_CHANGED);
            intent.putExtra(Intent.EXTRA_USER_HANDLE, userId);
            intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
            try {
                am.broadcastIntent(null, intent, null, null,
                        0, null, null, null, android.app.AppOpsManager.OP_NONE,