summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--nova/virt/disk/mount.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/nova/virt/disk/mount.py b/nova/virt/disk/mount.py
index c9afb9a74..a7ea77097 100644
--- a/nova/virt/disk/mount.py
+++ b/nova/virt/disk/mount.py
@@ -61,7 +61,7 @@ class Mount(object):
assert(os.path.exists(self.device))
if self.partition:
- map_path = '/dev/mapper/%sp%s' % (self.device.split('/')[-1],
+ map_path = '/dev/mapper/%sp%s' % (os.path.basename(self.device),
self.partition)
assert(not os.path.exists(map_path))