clean up statvfs

This commit is contained in:
Marcos Pinto 2007-09-15 15:51:19 +00:00
parent 82e7eb2e32
commit 2e461091dd
1 changed files with 1 additions and 2 deletions

View File

@ -54,8 +54,6 @@ import re
import shutil
import platform
import common
if not common.windows_check():
import statvfs
import time
import deluge_core
@ -798,6 +796,7 @@ class Manager:
def calc_free_space(self, directory):
if not common.windows_check():
import statvfs
dir_stats = os.statvfs(directory)
block_size = dir_stats[statvfs.F_BSIZE]
avail_blocks = dir_stats[statvfs.F_BAVAIL]