From 8ca9c2121a1b14665ef2b9c787ecf36957575ba1 Mon Sep 17 00:00:00 2001 From: Julien Duponchelle Date: Tue, 17 Mar 2015 18:34:23 +0100 Subject: [PATCH] Do not crash if iourc file is missing --- gns3server/modules/iou/iou_vm.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gns3server/modules/iou/iou_vm.py b/gns3server/modules/iou/iou_vm.py index cb5f917d..7323b9d7 100644 --- a/gns3server/modules/iou/iou_vm.py +++ b/gns3server/modules/iou/iou_vm.py @@ -370,6 +370,8 @@ class IOUVM(BaseVM): return config = configparser.ConfigParser() + if self.iourc_path is None: + raise IOUError("Could not found iourc file") try: with open(self.iourc_path) as f: config.read_file(f)