Merge "Handle renamed packages during default grants"

am: 140b101fcd

* commit '140b101fcdbdf413b914b5625b19577784ad9d88':
  Handle renamed packages during default grants
This commit is contained in:
Svetoslav Ganov
2015-11-17 20:06:21 +00:00
committed by android-build-merger

View File

@@ -871,7 +871,7 @@ final class DefaultPermissionGrantPolicy {
return false;
}
PackageSetting sysPkg = mService.mSettings.getDisabledSystemPkgLPr(pkg.packageName);
if (sysPkg != null) {
if (sysPkg != null && sysPkg.pkg != null) {
if ((sysPkg.pkg.applicationInfo.flags & ApplicationInfo.FLAG_PERSISTENT) == 0) {
return false;
}