(path)
| 93 | |
| 94 | |
| 95 | def getdrivesize(path): |
| 96 | if _platform == "win32": |
| 97 | free_bytes = ctypes.c_ulonglong(0) |
| 98 | ctypes.windll.kernel32.GetDiskFreeSpaceExW( |
| 99 | ctypes.c_wchar_p(path), None, None, ctypes.pointer(free_bytes)) |
| 100 | return free_bytes.value |
| 101 | |
| 102 | |
| 103 | # split extension for files |