diff options
Diffstat (limited to 'core/java/android')
| -rw-r--r-- | core/java/android/app/LoadedApk.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/core/java/android/app/LoadedApk.java b/core/java/android/app/LoadedApk.java index 4b84ed4adc30..ca3257f24207 100644 --- a/core/java/android/app/LoadedApk.java +++ b/core/java/android/app/LoadedApk.java @@ -736,7 +736,13 @@ public final class LoadedApk { } if (!libPaths.isEmpty() && SystemProperties.getBoolean(PROPERTY_NAME_APPEND_NATIVE, true)) { - ApplicationLoaders.getDefault().addNative(mClassLoader, libPaths); + // Temporarily disable logging of disk reads on the Looper thread as this is necessary + StrictMode.ThreadPolicy oldPolicy = StrictMode.allowThreadDiskReads(); + try { + ApplicationLoaders.getDefault().addNative(mClassLoader, libPaths); + } finally { + StrictMode.setThreadPolicy(oldPolicy); + } } if (addedPaths != null && addedPaths.size() > 0) { |
