dom0/core: guid for HVM is connected to stubdom - respect it when checking its state (#25 pro)

This commit is contained in:
Marek Marczykowski 2012-04-28 02:51:43 +02:00
parent 1b9e780861
commit 2ec08734dd

View File

@ -2375,6 +2375,14 @@ class QubesHVm(QubesVm):
xc.domain_unpause(self.stubdom_xid)
super(QubesHVm, self).unpause()
def is_fully_usable(self):
xid = self.stubdom_xid
if xid < 0:
return False
if not os.path.exists('/var/run/qubes/guid_running.%d' % xid):
return False
return True
class QubesVmCollection(dict):
"""
A collection of Qubes VMs indexed by Qubes id (qid)