From 4f6893978005551e5a2704348663888419f4f824 Mon Sep 17 00:00:00 2001 From: funkyk Date: Thu, 23 Feb 2017 14:11:18 +0900 Subject: [PATCH] debug in get_disk_info() --- src/common/utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common/utils.py b/src/common/utils.py index 55ec050..9e6c624 100644 --- a/src/common/utils.py +++ b/src/common/utils.py @@ -50,7 +50,8 @@ def get_disk_info(): for disk in disks: row = disk.split() if row[filesystem_index].startswith('/'): - st = os.statvfs(row[mounted_on_index]) + #st = os.statvfs(row[mounted_on_index]) causes an error with a disk name contining white spaces + st = os.statvfs(" ".join(row[mounted_on_index:])) disk_info.append({ 'mount': row[mounted_on_index], 'size': calculate_human_readable_filesize(st.f_frsize * st.f_blocks),