Bug 795478 - Remove blizzard fudge from xpcom io code. r=bsmedberg

This commit is contained in:
Doug Turner
2012-10-01 20:44:47 -07:00
parent 1adb4ec3a9
commit 4d09f9eade

View File

@@ -1227,12 +1227,8 @@ nsLocalFile::GetDiskSpaceAvailable(int64_t *aDiskSpaceAvailable)
#endif
return NS_ERROR_FAILURE;
}
/*
* The number of bytes free == The number of free blocks available to
* a non-superuser, minus one as a fudge factor, multiplied by the size
* of the aforementioned blocks.
*/
*aDiskSpaceAvailable = (int64_t)fs_buf.F_BSIZE * (fs_buf.f_bavail - 1);
*aDiskSpaceAvailable = (int64_t) fs_buf.F_BSIZE * fs_buf.f_bavail;
#ifdef DEBUG_DISK_SPACE
printf("DiskSpaceAvailable: %lu bytes\n",