Improved stability. 65/7365/1
authorpeusterm <manuel.peuster@uni-paderborn.de>
Mon, 25 Mar 2019 15:15:26 +0000 (16:15 +0100)
committerpeusterm <manuel.peuster@uni-paderborn.de>
Mon, 25 Mar 2019 15:15:26 +0000 (16:15 +0100)
Change-Id: Ic949c35bcb6c4c1e26e7bead243d41b50044812e
Signed-off-by: peusterm <manuel.peuster@uni-paderborn.de>
src/emuvim/dcemulator/net.py

index 64c173b..9e491b3 100755 (executable)
@@ -937,9 +937,12 @@ class DCNetwork(Containernet):
         :return:
         """
         # try it nicely
-        if self.ryu_process is not None:
-            self.ryu_process.terminate()
-            self.ryu_process.kill()
+        try:
+            if self.ryu_process is not None:
+                self.ryu_process.terminate()
+                self.ryu_process.kill()
+        except BaseException as ex:
+            LOG.warning("Error during Ryu stop: {}".format(ex))
         # ensure its death ;-)
         Popen(['pkill', '-f', 'ryu-manager'])