force disk space calc to Long on < android-18

closes #1424
This commit is contained in:
Hans-Christoph Steiner 2018-04-23 11:37:04 +02:00
parent ca57fcedc0
commit 4c555c2297

View File

@ -146,7 +146,7 @@ public final class Utils {
}
StatFs stat = new StatFs(statDir.getPath());
if (Build.VERSION.SDK_INT < 18) {
return stat.getAvailableBlocks() * stat.getBlockSize();
return (long) stat.getAvailableBlocks() * (long) stat.getBlockSize();
} else {
return stat.getAvailableBlocksLong() * stat.getBlockSizeLong();
}
@ -162,7 +162,7 @@ public final class Utils {
}
StatFs stat = new StatFs(statDir.getPath());
if (Build.VERSION.SDK_INT < 18) {
return stat.getBlockCount() * stat.getBlockSize();
return (long) stat.getBlockCount() * (long) stat.getBlockSize();
} else {
return stat.getBlockCountLong() * stat.getBlockSizeLong();
}