From bd4de862c889c655fc02aebe56a2cfba4b952bc7 Mon Sep 17 00:00:00 2001 From: Julien Duponchelle Date: Fri, 28 Oct 2016 11:25:14 +0200 Subject: [PATCH] Explain that segfault on IOU is a issue with the image Fix #739 --- gns3server/modules/iou/iou_vm.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/gns3server/modules/iou/iou_vm.py b/gns3server/modules/iou/iou_vm.py index 4105b55c..f58612a6 100644 --- a/gns3server/modules/iou/iou_vm.py +++ b/gns3server/modules/iou/iou_vm.py @@ -536,14 +536,19 @@ class IOUVM(BaseVM): :param returncode: Process returncode """ - log.info("{} process has stopped, return code: {}".format(process_name, returncode)) self._terminate_process_iou() self._terminate_process_iouyap() self._ioucon_thread_stop_event.set() + if returncode != 0: - self.project.emit("log.error", {"message": "{} process has stopped, return code: {}\n{}".format(process_name, - returncode, - self.read_iou_stdout())}) + log.info("{} process has stopped, return code: {}".format(process_name, returncode)) + else: + if returncode == 11: + message = "{} process has stopped, return code: {}. This could be an issue with the image using a different image can fix the issue.\n{}".format(process_name, returncode, self.read_iou_stdout()) + else: + message = "{} process has stopped, return code: {}\n{}".format(process_name, returncode, self.read_iou_stdout()) + log.warn(message) + self.project.emit("log.error", {"message": message}) def _rename_nvram_file(self): """