summaryrefslogtreecommitdiffstats
path: root/core/java
diff options
context:
space:
mode:
authorAmith Yamasani <yamasani@google.com>2012-08-19 07:54:36 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-08-19 07:54:36 -0700
commit67645821a5c1501edac684b876e49562c70a9424 (patch)
treebb78a6259c80242fda429fecb772264afc6832c1 /core/java
parentf337a89b4d6f6fd0a49b6edd7f895f06cb96d28b (diff)
parent11de39a5cfa41e6518b7e9d171a0dc5888538c94 (diff)
downloadframeworks_base-67645821a5c1501edac684b876e49562c70a9424.zip
frameworks_base-67645821a5c1501edac684b876e49562c70a9424.tar.gz
frameworks_base-67645821a5c1501edac684b876e49562c70a9424.tar.bz2
Merge "Don't create cache directory for isolated processes" into jb-mr1-dev
Diffstat (limited to 'core/java')
-rw-r--r--core/java/android/app/ActivityThread.java11
1 files changed, 6 insertions, 5 deletions
diff --git a/core/java/android/app/ActivityThread.java b/core/java/android/app/ActivityThread.java
index 7eb86f4..0438e77 100644
--- a/core/java/android/app/ActivityThread.java
+++ b/core/java/android/app/ActivityThread.java
@@ -4055,13 +4055,14 @@ public final class ActivityThread {
final ContextImpl appContext = new ContextImpl();
appContext.init(data.info, null, this);
- final File cacheDir = appContext.getCacheDir();
+ if (!Process.isIsolated()) {
+ final File cacheDir = appContext.getCacheDir();
- // Provide a usable directory for temporary files
- System.setProperty("java.io.tmpdir", cacheDir.getAbsolutePath());
-
- setupGraphicsSupport(data.info, cacheDir);
+ // Provide a usable directory for temporary files
+ System.setProperty("java.io.tmpdir", cacheDir.getAbsolutePath());
+ setupGraphicsSupport(data.info, cacheDir);
+ }
/**
* For system applications on userdebug/eng builds, log stack
* traces of disk and network access to dropbox for analysis.