From 946658c79ff37792b613193501bf973d52987e8c Mon Sep 17 00:00:00 2001 From: Asmir Avdicevic Date: Tue, 25 Jun 2024 14:21:19 +0200 Subject: [PATCH] fix: termination condition --- netsim/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/netsim/main.py b/netsim/main.py index aad3333..86c8a78 100644 --- a/netsim/main.py +++ b/netsim/main.py @@ -161,7 +161,7 @@ def run(nodes, prefix, args, debug=False, visualize=False): if r is None: p.terminate() process_errors.append('Process has timed out: %s' % prefix) - if r != 0: + elif r != 0: process_errors.append('Process has failed: %s with exit code: %d' % (prefix, r)) else: p.terminate()