diff options
author | Jan Synacek <jsynacek@redhat.com> | 2014-03-07 10:03:14 +0100 |
---|---|---|
committer | Jan Synacek <jsynacek@redhat.com> | 2014-03-07 10:19:08 +0100 |
commit | 12187958f92cbe80e172b289a63070bec9c9aaf7 (patch) | |
tree | 82d67a49bd9c4cd827cc09bd250b249a3d747210 /commands/storage/lmi | |
parent | e460bf50714c93df195a5648a9943bca0041145f (diff) | |
download | openlmi-scripts-12187958f92cbe80e172b289a63070bec9c9aaf7.tar.gz openlmi-scripts-12187958f92cbe80e172b289a63070bec9c9aaf7.tar.xz openlmi-scripts-12187958f92cbe80e172b289a63070bec9c9aaf7.zip |
storage: correctly report mounting errors
Diffstat (limited to 'commands/storage/lmi')
-rw-r--r-- | commands/storage/lmi/scripts/storage/mount.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/commands/storage/lmi/scripts/storage/mount.py b/commands/storage/lmi/scripts/storage/mount.py index c94bc5a..e379d0b 100644 --- a/commands/storage/lmi/scripts/storage/mount.py +++ b/commands/storage/lmi/scripts/storage/mount.py @@ -178,9 +178,8 @@ def mount_create(ns, device, mountpoint, fs_type=None, options=None): FileSystemSpec=device) msg = '%s on %s' % (device, mountpoint) if ret != 0: - errname = service.SyncCreateMount.CreateMountValues.value_name(ret) - raise LmiFailed('Cannot create mount: %s: %s.' % ( - msg, errname)) + raise LmiFailed('Cannot create mount: %s: %s' % ( + msg, _err)) LOG().info('Successfully created mount: %s', msg) |