diff mbox series

[v8,09/13] qemu.py: always cleanup on shutdown()

Message ID 20170901112829.2571-10-apahim@redhat.com
State New
Headers show
Series scripts/qemu.py fixes and cleanups | expand

Commit Message

Amador Pahim Sept. 1, 2017, 11:28 a.m. UTC
Currently we only cleanup on shutdown() if the VM is running.

To make sure we will always cleanup, this patch makes the cleanup to
always happen in shutdown, regardless the VM running state.

Signed-off-by: Amador Pahim <apahim@redhat.com>
---
 scripts/qemu.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Fam Zheng Sept. 5, 2017, 3:07 a.m. UTC | #1
On Fri, 09/01 13:28, Amador Pahim wrote:
> Currently we only cleanup on shutdown() if the VM is running.
> 
> To make sure we will always cleanup, this patch makes the cleanup to
> always happen in shutdown, regardless the VM running state.
> 
> Signed-off-by: Amador Pahim <apahim@redhat.com>

Reviewed-by: Fam Zheng <famz@redhat.com>
diff mbox series

Patch

diff --git a/scripts/qemu.py b/scripts/qemu.py
index 06f07bfaa2..ede734328b 100644
--- a/scripts/qemu.py
+++ b/scripts/qemu.py
@@ -205,8 +205,8 @@  class QEMUMachine(object):
                 self._popen.kill()
             self._popen.wait()
 
-            self._load_io_log()
-            self._post_shutdown()
+        self._load_io_log()
+        self._post_shutdown()
 
         exitcode = self.exitcode()
         if exitcode is not None and exitcode < 0: