1
0
Fork 0

disk: check if device is removable more safely

This commit is contained in:
Jan Vcelak 2013-01-22 18:34:19 +01:00
parent 01ef388113
commit 50a46c6607

View file

@ -32,7 +32,7 @@ class DiskPlugin(base.Plugin):
def _device_is_supported(cls, device):
return device.device_type == "disk" \
and device.attributes["removable"] == "0" \
and device.attributes.get("removable", None) == "0" \
and device.parent is not None \
and device.parent.subsystem in ["scsi", "virtio"]