[blivet] Allow / in the name of all kinds of btrfs device (#1183061)
David Shea
dshea at redhat.com
Fri Jan 16 18:38:44 UTC 2015
---
blivet/devices/btrfs.py | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/blivet/devices/btrfs.py b/blivet/devices/btrfs.py
index 13adbb4..b5df2d0 100644
--- a/blivet/devices/btrfs.py
+++ b/blivet/devices/btrfs.py
@@ -138,6 +138,11 @@ class BTRFSDevice(StorageDevice):
spec = super(BTRFSDevice, self).fstabSpec
return spec
+ @classmethod
+ def isNameValid(cls, name):
+ # Override StorageDevice.isNameValid to allow /
+ return not('\x00' in name or name == '.' or name == '..')
+
class BTRFSVolumeDevice(BTRFSDevice, ContainerDevice, RaidDevice):
_type = "btrfs volume"
vol_id = btrfs.MAIN_VOLUME_ID
@@ -567,11 +572,6 @@ class BTRFSSubVolumeDevice(BTRFSDevice, RaidDevice):
data.name = self.name
data.preexist = self.exists
- @classmethod
- def isNameValid(cls, name):
- # Override StorageDevice.isNameValid to allow /
- return not('\x00' in name or name == '.' or name == '..')
-
class BTRFSSnapShotDevice(BTRFSSubVolumeDevice):
""" A btrfs snapshot pseudo-device.
--
2.1.0
More information about the anaconda-patches
mailing list