remove fsize

This commit is contained in:
Marcos Pinto 2008-09-21 20:09:34 +00:00
parent 0712da0fd0
commit cf6266e545
1 changed files with 2 additions and 2 deletions

View File

@ -391,8 +391,8 @@ def free_space(path):
import win32api import win32api
drive = path.split(":")[0] drive = path.split(":")[0]
free = win32api.GetDiskFreeSpaceEx(drive)[0] free = win32api.GetDiskFreeSpaceEx(drive)[0]
return fsize(free) return free
else: else:
disk_data = os.statvfs(path) disk_data = os.statvfs(path)
block_size = disk_data.f_bsize block_size = disk_data.f_bsize
return fsize(disk_data.f_bavail * block_size) return disk_data.f_bavail * block_size