Index: chrome/android/java/src/org/chromium/chrome/browser/webapps/FullScreenActivityTab.java |
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/webapps/FullScreenActivityTab.java b/chrome/android/java/src/org/chromium/chrome/browser/webapps/FullScreenActivityTab.java |
index b56263eb1815623e7f0394a73eaade0107b3163d..74ebf39fded3976ddeb09fac277e16e92f73b658 100644 |
--- a/chrome/android/java/src/org/chromium/chrome/browser/webapps/FullScreenActivityTab.java |
+++ b/chrome/android/java/src/org/chromium/chrome/browser/webapps/FullScreenActivityTab.java |
@@ -8,6 +8,7 @@ import android.content.Context; |
import android.content.Intent; |
import android.net.Uri; |
import android.os.Bundle; |
+import android.os.StrictMode; |
import android.text.TextUtils; |
import android.util.Log; |
import android.view.ContextMenu; |
@@ -141,6 +142,9 @@ public class FullScreenActivityTab extends ChromeTab { |
File tabFile = getTabFile(activityDirectory, getId()); |
FileOutputStream foutput = null; |
+ // Temporarily allowing disk access while fixing. TODO: http://crbug.com/525781 |
+ StrictMode.ThreadPolicy oldPolicy = StrictMode.allowThreadDiskReads(); |
+ StrictMode.allowThreadDiskWrites(); |
try { |
foutput = new FileOutputStream(tabFile); |
TabState.saveState(foutput, getState(), false); |
@@ -150,6 +154,7 @@ public class FullScreenActivityTab extends ChromeTab { |
Log.e(TAG, "Failed to save out tab state.", exception); |
} finally { |
StreamUtil.closeQuietly(foutput); |
+ StrictMode.setThreadPolicy(oldPolicy); |
} |
} |