From 7f7cd29cb77472f296f0e2be2ba8d317633be030 Mon Sep 17 00:00:00 2001 From: hygienic-books Date: Tue, 5 Jul 2022 18:00:25 +0200 Subject: [PATCH] refactor(debug): Exit code 13 is now 4 which had become unused --- update-firewall-source.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/update-firewall-source.py b/update-firewall-source.py index 2533087..36c4bfd 100644 --- a/update-firewall-source.py +++ b/update-firewall-source.py @@ -30,7 +30,7 @@ import difflib # 1 : Config file invalid, it has no sections # 2 : Config file invalid, sections must define at least CONST.CFG_MANDATORY # 3 : No physical network device found at "/sys/class/net" -# 4 : Performing a firewalld rules encountered a FileNotFoundError +# 4 : Linux find command exited non-zero trying to find a physical network device at "/sys/class/net" # 5 : Unable to open firewalld direct rules file for reading # 6 : Source and destination are identical when attempting to back up firewalld direct rules file # 7 : An option that must have a non-null value is either unset or null @@ -39,7 +39,6 @@ import difflib # 10: Unable to restart systemd firewalld.service unit # 11: Unable to add a tag to firewalld # 12: Kernel sysfs export for network devices at "/sys/class/net" doesn't exist -# 13: Linux find command exited non-zero trying to find a physical network device at "/sys/class/net" class CONST(object): @@ -342,8 +341,8 @@ def get_phy_nics() -> list: f"{cpe.cmd}\n" f"Verbatim command output was:\n" f"{cpe.output.rstrip()}\n" - f"Exiting 13 ...") - sys.exit(13) + f"Exiting 4 ...") + sys.exit(4) else: if not phy_nics_find.stdout: log.error(f"No physical network device found at {linux_sysfs_nics_abs!r}.\n"