From 22e4fec2e2b46df56f9e54e543924c3fcd5eaa68 Mon Sep 17 00:00:00 2001 From: Julien Duponchelle Date: Fri, 11 Sep 2015 14:16:56 +0200 Subject: [PATCH] Fix ProcessLookupError on _checkAlive Qemu Fix #308 --- gns3server/modules/qemu/qemu_vm.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gns3server/modules/qemu/qemu_vm.py b/gns3server/modules/qemu/qemu_vm.py index 5d2c95e9..35bf228e 100644 --- a/gns3server/modules/qemu/qemu_vm.py +++ b/gns3server/modules/qemu/qemu_vm.py @@ -907,7 +907,10 @@ class QemuVM(BaseVM): self._process.terminate() yield from gns3server.utils.asyncio.wait_for_process_termination(self._process, timeout=3) except asyncio.TimeoutError: - self._process.kill() + try: + self._process.kill() + except ProcessLookupError: + pass if self._process.returncode is None: log.warn('QEMU VM "{}" PID={} is still running'.format(self._name, self._process.pid)) self._process = None