diff options
author | Cole Robinson <crobinso@redhat.com> | 2014-03-12 11:51:15 -0400 |
---|---|---|
committer | Cole Robinson <crobinso@redhat.com> | 2014-03-12 11:51:15 -0400 |
commit | d2ad2bcf942cec5836b576a76130a0253290e83a (patch) | |
tree | 5476d703e92fbe7ff64c45cbb2a612a2d501292f | |
parent | 1230ab57a963841009e404c10ef431c2cdc3dd83 (diff) | |
download | virt-manager-d2ad2bcf942cec5836b576a76130a0253290e83a.tar.gz |
create: Clarify some bits in change_caps
-rw-r--r-- | virtManager/create.py | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/virtManager/create.py b/virtManager/create.py index b6f4c8c3..757d7009 100644 --- a/virtManager/create.py +++ b/virtManager/create.py @@ -847,9 +847,8 @@ class vmmCreate(vmmGObjectUI): def change_caps(self, gtype=None, arch=None): if gtype is None: - # If none specified, prefer HVM. This way, the default install - # options won't be limited because we default to PV. If hvm not - # supported, differ to guest_lookup + # If none specified, prefer HVM so install options aren't limited + # with a default PV choice. for g in self.conn.caps.guests: if g.os_type == "hvm": gtype = "hvm" @@ -857,10 +856,7 @@ class vmmCreate(vmmGObjectUI): (newg, newdom) = self.conn.caps.guest_lookup(os_type=gtype, arch=arch) - if (self.capsguest and self.capsdomain and - (newg.arch == self.capsguest.arch and - newg.os_type == self.capsguest.os_type)): - # No change + if self.capsguest == newg and self.capsdomain and newdom: return self.capsguest = newg |