Skip to content
This repository has been archived by the owner on Apr 26, 2020. It is now read-only.

Commit

Permalink
Proxy fix state naming
Browse files Browse the repository at this point in the history
  • Loading branch information
kalkin committed Oct 3, 2016
1 parent 4120cf6 commit cda2e8c
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions qubesdbus/proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,12 @@ def forward_vm_event(self, vm, event, *args, **kwargs):
log.error('Could not add vm via to dbus DomainManager')
log.info('Added VM %s', data)
self.new_vm.remove(vm)
elif event == 'domain-start':
proxy = vm_proxy(vm.qid)
if kwargs['start_guid'] == True:
property_set(proxy, 'state', 'qrexec_running')
else:
property_set(proxy, 'state', 'running')
elif event == 'domain-shutdown':
proxy = vm_proxy(vm.qid)
property_set(proxy, 'state', 'halted')
elif event == 'domain-start':
proxy = vm_proxy(vm.qid)
property_set(proxy, 'state', 'Running')
elif event == 'domain-shutdown':
proxy = vm_proxy(vm.qid)
property_set(proxy, 'state', 'Halted')
else:
log.warn('Unknown %s from %s %s %s', event, vm, args, kwargs)

Expand Down

0 comments on commit cda2e8c

Please sign in to comment.