TODO: explain why
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
scripts/qemu.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/scripts/qemu.py b/scripts/qemu.py
index e19e4b34d0..aaba04b3c1 100644
--- a/scripts/qemu.py
+++ b/scripts/qemu.py
@@ -275,7 +275,8 @@ class QEMUMachine(object):
def wait(self):
'''Wait for the VM to power off'''
- self._popen.wait()
+ if self.is_running():
+ self._popen.wait()
self._post_shutdown()
def shutdown(self):
--
2.14.3