summaryrefslogtreecommitdiff
path: root/core/java/android
diff options
context:
space:
mode:
authorJeff Sharkey <jsharkey@android.com>2017-03-14 23:37:35 -0600
committerJeff Sharkey <jsharkey@android.com>2017-03-14 23:39:03 -0600
commite730ae877a24d44f5b3db096f08b0a2d7399aa2d (patch)
tree9b4dcc9d2e4ba38726ced0f55012cdc02a56e51f /core/java/android
parentb94427d2855c4fc5b62890fdb99ceca140b5034d (diff)
Enable cache clearing v2 logic, fix bugs.
Now that we have CTS tests to verify the cache clearing v2 logic, we're ready to enable it! Switch storage APIs over to "usable space" to match implementation down in installd. Add a missing clearCallingIdentity(), and offer better logging for missing appop permission. Load quotas from disk right away at device boot instead of waiting. Bug: 35685848, 35684969 Test: cts-tradefed run commandAndExit cts-dev -m CtsAppSecurityHostTestCases -t android.appsecurity.cts.StorageHostTest Change-Id: I8167e0322b4662ca6c975da5c50715e2d71332a7
Diffstat (limited to 'core/java/android')
-rw-r--r--core/java/android/app/usage/StorageStatsManager.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/java/android/app/usage/StorageStatsManager.java b/core/java/android/app/usage/StorageStatsManager.java
index 82762293a241..b808c2b75203 100644
--- a/core/java/android/app/usage/StorageStatsManager.java
+++ b/core/java/android/app/usage/StorageStatsManager.java
@@ -81,9 +81,9 @@ public class StorageStatsManager {
/**
* Return the free space on the requested storage volume.
* <p>
- * The free space is equivalent to {@link File#getFreeSpace()} plus the size
- * of any cached data that can be automatically deleted by the system as
- * additional space is needed.
+ * The free space is equivalent to {@link File#getUsableSpace()} plus the
+ * size of any cached data that can be automatically deleted by the system
+ * as additional space is needed.
* <p>
* This method may take several seconds to calculate the requested values,
* so it should only be called from a worker thread.