inspection: exclude cdrom from vm inspection

Can cause inspection to fail if cdrom is the first device
See: https://bugzilla.redhat.com/show_bug.cgi?id=752552

(crobinso: added Lars to AUTHORS, expanded commit msg)
This commit is contained in:
Lars Sjostrom 2011-11-09 21:05:49 +01:00 committed by Cole Robinson
parent a712a7b32e
commit 9d2119ab3e
2 changed files with 3 additions and 1 deletions

View File

@ -71,6 +71,7 @@ Further patches have been submitted by:
Gerhard Stenzel <gerhard-dot-stenzel-at-de-dot-ibm-dot-com>
Yuri Chornoivan <yurchor-at-ukr-dot-net>
Miklos Vajna <vmiklos-at-frugalware-dot-org>
Lars Sjostrom <lars-at-radicore-dot-se>
<...send a patch & get your name here...>

View File

@ -140,7 +140,8 @@ class vmmInspection(vmmGObject):
disks = []
for disk in vm.get_disk_devices():
if (disk.path and
(disk.type == "block" or disk.type == "file")):
(disk.type == "block" or disk.type == "file") and
not disk.device == "cdrom"):
disks.append(disk)
if not disks: