From 4ea96d2485971dbdafe921ca65967f8385450f11 Mon Sep 17 00:00:00 2001 From: John Estabrook Date: Tue, 15 Aug 2023 21:40:56 -0500 Subject: T5483: clean up tmp config file --- src/conf_mode/dhcp_server.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src') diff --git a/src/conf_mode/dhcp_server.py b/src/conf_mode/dhcp_server.py index 280057f04..c4c72aae9 100755 --- a/src/conf_mode/dhcp_server.py +++ b/src/conf_mode/dhcp_server.py @@ -296,6 +296,10 @@ def generate(dhcp): render(config_file, 'dhcp-server/dhcpd.conf.j2', dhcp, formater=lambda _: _.replace(""", '"')) + # Clean up configuration test file + if os.path.exists(tmp_file): + os.unlink(tmp_file) + return None def apply(dhcp): -- cgit v1.2.3