core: cleanup_vifs should not fail when no network intf is present
This can happen when initially there was no default netvm, some domain was started, then default netvm was set and started - then netvm.connected_vms will contain domains which aren't really connected there. Especially this was happening in firstboot.
This commit is contained in:
parent
db28551807
commit
bbf2ee3a67
@ -991,7 +991,7 @@ class QubesVm(object):
|
||||
return
|
||||
|
||||
dev_basepath = '/local/domain/%d/device/vif' % self.xid
|
||||
for dev in vmm.xs.ls('', dev_basepath):
|
||||
for dev in (vmm.xs.ls('', dev_basepath) or []):
|
||||
# check if backend domain is alive
|
||||
backend_xid = int(vmm.xs.read('', '%s/%s/backend-id' % (dev_basepath, dev)))
|
||||
if backend_xid in vmm.libvirt_conn.listDomainsID():
|
||||
|
Loading…
Reference in New Issue
Block a user