Make package verifier broadcasts foreground.

We're using ordered broadcasts (sigh!) for package verification, and
we could be stuck behind dozens of other background broadcasts, so
hoist into foreground queue.

Bug: 18356768
Change-Id: Ib4abf771db0147f8fbd7227f32297602816c84ae
This commit is contained in:
Jeff Sharkey
2014-11-13 12:13:53 -08:00
parent 521ca5f8fb
commit 13cf7917af

View File

@@ -8982,6 +8982,7 @@ public class PackageManagerService extends IPackageManager.Stub {
&& isVerificationEnabled(userIdentifier, installFlags)) {
final Intent verification = new Intent(
Intent.ACTION_PACKAGE_NEEDS_VERIFICATION);
verification.addFlags(Intent.FLAG_RECEIVER_FOREGROUND);
verification.setDataAndType(Uri.fromFile(new File(origin.resolvedPath)),
PACKAGE_MIME_TYPE);
verification.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);