Loading services/java/com/android/server/pm/PackageManagerService.java +7 −1 Original line number Diff line number Diff line Loading @@ -3586,6 +3586,12 @@ public class PackageManagerService extends IPackageManager.Stub { + " to " + scanFile); updatedPkg.codePath = scanFile; updatedPkg.codePathString = scanFile.toString(); // This is the point at which we know that the system-disk APK // for this package has moved during a reboot (e.g. due to an OTA), // so we need to reevaluate it for privilege policy. if (locationIsPrivileged(scanFile)) { updatedPkg.pkgFlags |= ApplicationInfo.FLAG_PRIVILEGED; } } updatedPkg.pkg = pkg; mLastScanError = PackageManager.INSTALL_FAILED_DUPLICATE_PACKAGE; Loading services/java/com/android/server/pm/Settings.java +6 −6 Original line number Diff line number Diff line Loading @@ -426,12 +426,12 @@ final class Settings { + "; replacing with new"); p = null; } else { if ((pkgFlags&ApplicationInfo.FLAG_SYSTEM) != 0) { // If what we are scanning is a system package, then // make it so, regardless of whether it was previously // installed only in the data partition. p.pkgFlags |= ApplicationInfo.FLAG_SYSTEM; } // If what we are scanning is a system (and possibly privileged) package, // then make it so, regardless of whether it was previously installed only // in the data partition. final int sysPrivFlags = pkgFlags & (ApplicationInfo.FLAG_SYSTEM | ApplicationInfo.FLAG_PRIVILEGED); p.pkgFlags |= sysPrivFlags; } } if (p == null) { Loading Loading
services/java/com/android/server/pm/PackageManagerService.java +7 −1 Original line number Diff line number Diff line Loading @@ -3586,6 +3586,12 @@ public class PackageManagerService extends IPackageManager.Stub { + " to " + scanFile); updatedPkg.codePath = scanFile; updatedPkg.codePathString = scanFile.toString(); // This is the point at which we know that the system-disk APK // for this package has moved during a reboot (e.g. due to an OTA), // so we need to reevaluate it for privilege policy. if (locationIsPrivileged(scanFile)) { updatedPkg.pkgFlags |= ApplicationInfo.FLAG_PRIVILEGED; } } updatedPkg.pkg = pkg; mLastScanError = PackageManager.INSTALL_FAILED_DUPLICATE_PACKAGE; Loading
services/java/com/android/server/pm/Settings.java +6 −6 Original line number Diff line number Diff line Loading @@ -426,12 +426,12 @@ final class Settings { + "; replacing with new"); p = null; } else { if ((pkgFlags&ApplicationInfo.FLAG_SYSTEM) != 0) { // If what we are scanning is a system package, then // make it so, regardless of whether it was previously // installed only in the data partition. p.pkgFlags |= ApplicationInfo.FLAG_SYSTEM; } // If what we are scanning is a system (and possibly privileged) package, // then make it so, regardless of whether it was previously installed only // in the data partition. final int sysPrivFlags = pkgFlags & (ApplicationInfo.FLAG_SYSTEM | ApplicationInfo.FLAG_PRIVILEGED); p.pkgFlags |= sysPrivFlags; } } if (p == null) { Loading