Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 049315a0 authored by Android (Google) Code Review's avatar Android (Google) Code Review Committed by The Android Open Source Project
Browse files

am 7b59fe31: Merge change 1275 into donut

Merge commit '7b59fe31'

* commit '7b59fe31':
  Make the internal storage monitor work correctly when internal storage is very large.
parents ddf9856c 7b59fe31
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -74,7 +74,7 @@ class DeviceStorageMonitorService extends Binder {
    private boolean mLowMemFlag=false;
    private Context mContext;
    private ContentResolver mContentResolver;
    int mBlkSize;
    long mBlkSize;
    long mTotalMemory;
    StatFs mFileStats;
    private static final String DATA_PATH="/data";
@@ -251,7 +251,7 @@ class DeviceStorageMonitorService extends Binder {
        //initialize block size
        mBlkSize = mFileStats.getBlockSize();
        //initialize total storage on device
        mTotalMemory = (mFileStats.getBlockCount()*mBlkSize)/100;
        mTotalMemory = ((long)mFileStats.getBlockCount()*mBlkSize)/100L;
        mStorageLowIntent = new Intent(Intent.ACTION_DEVICE_STORAGE_LOW);
        mStorageOkIntent = new Intent(Intent.ACTION_DEVICE_STORAGE_OK);
        checkMemory(true);