From 66444f4952eeb422f069dd1c8ddded6facfa6243 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20K=C3=BChnel?= Date: Thu, 16 Apr 2020 11:06:26 +0200 Subject: [PATCH] checking existence before setting flags --- scripts/run_cmake.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/run_cmake.py b/scripts/run_cmake.py index bf9c57a..a89c1d4 100755 --- a/scripts/run_cmake.py +++ b/scripts/run_cmake.py @@ -153,6 +153,8 @@ def secure_delete(path: str): return def del_rw(action, name, exc): + if not os.path.exists(name): + return os.chmod(name, stat.S_IWRITE) os.remove(name)