mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
stream: fix sectors not allocated test
The test on sectors not allocated can fail if the L1/L2 tables are not on disk yet. Allow tests to shutdown the VM early. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
cc785c349d
commit
863a5d042f
2 changed files with 7 additions and 4 deletions
|
@ -87,10 +87,12 @@ class VM(object):
|
|||
|
||||
def shutdown(self):
|
||||
'''Terminate the VM and clean up'''
|
||||
self._qmp.cmd('quit')
|
||||
self._popen.wait()
|
||||
os.remove(self._monitor_path)
|
||||
os.remove(self._qemu_log_path)
|
||||
if not self._popen is None:
|
||||
self._qmp.cmd('quit')
|
||||
self._popen.wait()
|
||||
os.remove(self._monitor_path)
|
||||
os.remove(self._qemu_log_path)
|
||||
self._popen = None
|
||||
|
||||
def qmp(self, cmd, **args):
|
||||
'''Invoke a QMP command and return the result dict'''
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue