summaryrefslogtreecommitdiffstats
path: root/core/java/android/content
diff options
context:
space:
mode:
authorSteve Kondik <steve@cyngn.com>2015-05-29 15:36:36 -0700
committerClark Scheff <clark@cyngn.com>2015-10-27 18:21:29 -0700
commitd008d55f8ab1b1cf6e09aa49170f4b05f66ce764 (patch)
tree42bcfdd32d95074be3b6f4d40130efbacfc2ca91 /core/java/android/content
parent64e533079c0f2bec046b0c1f963ed8d8081e578e (diff)
downloadframeworks_base-d008d55f8ab1b1cf6e09aa49170f4b05f66ce764.zip
frameworks_base-d008d55f8ab1b1cf6e09aa49170f4b05f66ce764.tar.gz
frameworks_base-d008d55f8ab1b1cf6e09aa49170f4b05f66ce764.tar.bz2
themes: Fix strictmode warnings
* Use access() in the native layer instead of constructing a File object, as this will open the file and trigger a strictmode warning any time we hit this code path. Change-Id: I0ee93e84c4b6d4937fc1ab08975e1a4c10a80295
Diffstat (limited to 'core/java/android/content')
-rw-r--r--core/java/android/content/res/AssetManager.java6
1 files changed, 1 insertions, 5 deletions
diff --git a/core/java/android/content/res/AssetManager.java b/core/java/android/content/res/AssetManager.java
index ebbfd09..3329025 100644
--- a/core/java/android/content/res/AssetManager.java
+++ b/core/java/android/content/res/AssetManager.java
@@ -671,11 +671,7 @@ public final class AssetManager implements AutoCloseable {
public final int addCommonOverlayPath(String themeApkPath,
String resApkPath, String prefixPath) {
synchronized (this) {
- if ((new File(themeApkPath).exists()) && (new File(resApkPath).exists())) {
- return addCommonOverlayPathNative(themeApkPath, resApkPath, prefixPath);
- }
-
- return 0;
+ return addCommonOverlayPathNative(themeApkPath, resApkPath, prefixPath);
}
}