Loading core/java/android/app/ActivityThread.java +1 −1 Original line number Diff line number Diff line Loading @@ -5873,7 +5873,7 @@ public final class ActivityThread extends ClientTransactionHandler { } finally { // If the app targets < O-MR1, or doesn't change the thread policy // during startup, clobber the policy to maintain behavior of b/36951662 if (data.appInfo.targetSdkVersion <= Build.VERSION_CODES.O if (data.appInfo.targetSdkVersion < Build.VERSION_CODES.O_MR1 || StrictMode.getThreadPolicy().equals(writesAllowedPolicy)) { StrictMode.setThreadPolicy(savedPolicy); } Loading core/java/android/app/WallpaperManager.java +2 −2 Original line number Diff line number Diff line Loading @@ -413,7 +413,7 @@ public class WallpaperManager { } catch (OutOfMemoryError e) { Log.w(TAG, "Out of memory loading the current wallpaper: " + e); } catch (SecurityException e) { if (context.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.O) { if (context.getApplicationInfo().targetSdkVersion < Build.VERSION_CODES.O_MR1) { Log.w(TAG, "No permission to access wallpaper, suppressing" + " exception to avoid crashing legacy app."); } else { Loading Loading @@ -977,7 +977,7 @@ public class WallpaperManager { } catch (RemoteException e) { throw e.rethrowFromSystemServer(); } catch (SecurityException e) { if (mContext.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.O) { if (mContext.getApplicationInfo().targetSdkVersion < Build.VERSION_CODES.O_MR1) { Log.w(TAG, "No permission to access wallpaper, suppressing" + " exception to avoid crashing legacy app."); return null; Loading core/java/android/content/pm/ApplicationInfo.java +3 −3 Original line number Diff line number Diff line Loading @@ -1694,7 +1694,7 @@ public class ApplicationInfo extends PackageItemInfo implements Parcelable { if (mHiddenApiPolicy != HIDDEN_API_ENFORCEMENT_DEFAULT) { return mHiddenApiPolicy; } if (targetSdkVersion <= Build.VERSION_CODES.O_MR1) { if (targetSdkVersion < Build.VERSION_CODES.P) { return HIDDEN_API_ENFORCEMENT_BLACK; } else { return HIDDEN_API_ENFORCEMENT_DARK_GREY_AND_BLACK; Loading Loading @@ -1728,9 +1728,9 @@ public class ApplicationInfo extends PackageItemInfo implements Parcelable { if (isPackageWhitelistedForHiddenApis()) { return; } if (targetSdkVersion <= Build.VERSION_CODES.O_MR1) { if (targetSdkVersion < Build.VERSION_CODES.P) { setHiddenApiEnforcementPolicy(policyPreP); } else if (targetSdkVersion > Build.VERSION_CODES.O_MR1) { } else if (targetSdkVersion >= Build.VERSION_CODES.P) { setHiddenApiEnforcementPolicy(policyP); } Loading core/java/android/content/pm/PackageParser.java +1 −1 Original line number Diff line number Diff line Loading @@ -2716,7 +2716,7 @@ public class PackageParser { // Fot apps targeting O-MR1 we require explicit enumeration of all certs. String[] additionalCertSha256Digests = EmptyArray.STRING; if (pkg.applicationInfo.targetSdkVersion > Build.VERSION_CODES.O) { if (pkg.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.O_MR1) { additionalCertSha256Digests = parseAdditionalCertificates(res, parser, outError); if (additionalCertSha256Digests == null) { return false; Loading core/java/android/content/pm/PackageSharedLibraryUpdater.java +1 −1 Original line number Diff line number Diff line Loading @@ -62,7 +62,7 @@ public abstract class PackageSharedLibraryUpdater { static boolean apkTargetsApiLevelLessThanOrEqualToOMR1(PackageParser.Package pkg) { int targetSdkVersion = pkg.applicationInfo.targetSdkVersion; return targetSdkVersion <= Build.VERSION_CODES.O_MR1; return targetSdkVersion < Build.VERSION_CODES.P; } /** Loading Loading
core/java/android/app/ActivityThread.java +1 −1 Original line number Diff line number Diff line Loading @@ -5873,7 +5873,7 @@ public final class ActivityThread extends ClientTransactionHandler { } finally { // If the app targets < O-MR1, or doesn't change the thread policy // during startup, clobber the policy to maintain behavior of b/36951662 if (data.appInfo.targetSdkVersion <= Build.VERSION_CODES.O if (data.appInfo.targetSdkVersion < Build.VERSION_CODES.O_MR1 || StrictMode.getThreadPolicy().equals(writesAllowedPolicy)) { StrictMode.setThreadPolicy(savedPolicy); } Loading
core/java/android/app/WallpaperManager.java +2 −2 Original line number Diff line number Diff line Loading @@ -413,7 +413,7 @@ public class WallpaperManager { } catch (OutOfMemoryError e) { Log.w(TAG, "Out of memory loading the current wallpaper: " + e); } catch (SecurityException e) { if (context.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.O) { if (context.getApplicationInfo().targetSdkVersion < Build.VERSION_CODES.O_MR1) { Log.w(TAG, "No permission to access wallpaper, suppressing" + " exception to avoid crashing legacy app."); } else { Loading Loading @@ -977,7 +977,7 @@ public class WallpaperManager { } catch (RemoteException e) { throw e.rethrowFromSystemServer(); } catch (SecurityException e) { if (mContext.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.O) { if (mContext.getApplicationInfo().targetSdkVersion < Build.VERSION_CODES.O_MR1) { Log.w(TAG, "No permission to access wallpaper, suppressing" + " exception to avoid crashing legacy app."); return null; Loading
core/java/android/content/pm/ApplicationInfo.java +3 −3 Original line number Diff line number Diff line Loading @@ -1694,7 +1694,7 @@ public class ApplicationInfo extends PackageItemInfo implements Parcelable { if (mHiddenApiPolicy != HIDDEN_API_ENFORCEMENT_DEFAULT) { return mHiddenApiPolicy; } if (targetSdkVersion <= Build.VERSION_CODES.O_MR1) { if (targetSdkVersion < Build.VERSION_CODES.P) { return HIDDEN_API_ENFORCEMENT_BLACK; } else { return HIDDEN_API_ENFORCEMENT_DARK_GREY_AND_BLACK; Loading Loading @@ -1728,9 +1728,9 @@ public class ApplicationInfo extends PackageItemInfo implements Parcelable { if (isPackageWhitelistedForHiddenApis()) { return; } if (targetSdkVersion <= Build.VERSION_CODES.O_MR1) { if (targetSdkVersion < Build.VERSION_CODES.P) { setHiddenApiEnforcementPolicy(policyPreP); } else if (targetSdkVersion > Build.VERSION_CODES.O_MR1) { } else if (targetSdkVersion >= Build.VERSION_CODES.P) { setHiddenApiEnforcementPolicy(policyP); } Loading
core/java/android/content/pm/PackageParser.java +1 −1 Original line number Diff line number Diff line Loading @@ -2716,7 +2716,7 @@ public class PackageParser { // Fot apps targeting O-MR1 we require explicit enumeration of all certs. String[] additionalCertSha256Digests = EmptyArray.STRING; if (pkg.applicationInfo.targetSdkVersion > Build.VERSION_CODES.O) { if (pkg.applicationInfo.targetSdkVersion >= Build.VERSION_CODES.O_MR1) { additionalCertSha256Digests = parseAdditionalCertificates(res, parser, outError); if (additionalCertSha256Digests == null) { return false; Loading
core/java/android/content/pm/PackageSharedLibraryUpdater.java +1 −1 Original line number Diff line number Diff line Loading @@ -62,7 +62,7 @@ public abstract class PackageSharedLibraryUpdater { static boolean apkTargetsApiLevelLessThanOrEqualToOMR1(PackageParser.Package pkg) { int targetSdkVersion = pkg.applicationInfo.targetSdkVersion; return targetSdkVersion <= Build.VERSION_CODES.O_MR1; return targetSdkVersion < Build.VERSION_CODES.P; } /** Loading