summaryrefslogtreecommitdiff
path: root/bin/swift-drive-audit
diff options
context:
space:
mode:
authorSamuel Merritt <sam@swiftstack.com>2012-11-26 18:15:21 -0800
committerSamuel Merritt <sam@swiftstack.com>2012-11-26 18:15:21 -0800
commit35f4d29ed6562b0f4d5db253deeb218db62078a4 (patch)
tree3322a19e4ec87f4e010801887e96f7158ac46924 /bin/swift-drive-audit
parent2ad23a25e822224c824373ae6d2eaa12bcac4f6c (diff)
downloadswift-35f4d29ed6562b0f4d5db253deeb218db62078a4.tar.gz
Upgrade pep8 to 1.3.3.
This required a bunch of whitespace-poking of the scripts in bin, but that's all. Now every file in swift/ and bin/ is pep8-1.3.3-compliant, so hopefully we can be done with this pep8 stuff for a good long time. Change-Id: I44fdb41d219c57400a4c396ab7eb0ffa9dcd8db8
Diffstat (limited to 'bin/swift-drive-audit')
-rwxr-xr-xbin/swift-drive-audit8
1 files changed, 4 insertions, 4 deletions
diff --git a/bin/swift-drive-audit b/bin/swift-drive-audit
index e7926aeab..6c742a483 100755
--- a/bin/swift-drive-audit
+++ b/bin/swift-drive-audit
@@ -46,7 +46,7 @@ def get_devices(device_dir, logger):
except OSError, e:
# If we can't stat the device, then something weird is going on
logger.error("Error: Could not stat %s!" %
- block_device)
+ block_device)
continue
device['major'] = str(os.major(device_num))
device['minor'] = str(os.minor(device_num))
@@ -54,7 +54,7 @@ def get_devices(device_dir, logger):
for line in open('/proc/partitions').readlines()[2:]:
major, minor, blocks, kernel_device = line.strip().split()
device = [d for d in devices
- if d['major'] == major and d['minor'] == minor]
+ if d['major'] == major and d['minor'] == minor]
if device:
device[0]['kernel_device'] = kernel_device
return devices
@@ -127,10 +127,10 @@ if __name__ == '__main__':
mount_point = device[0]['mount_point']
if mount_point.startswith(device_dir):
logger.info("Unmounting %s with %d errors" %
- (mount_point, count))
+ (mount_point, count))
subprocess.call(['umount', '-fl', mount_point])
logger.info("Commenting out %s from /etc/fstab" %
- (mount_point))
+ (mount_point))
comment_fstab(mount_point)
unmounts += 1
if unmounts == 0: