osmith submitted this change.
scripts/osmotestconfig: copy_config: tweak mkdir
Run os.mkdir unconditionally, checking if it exists is not needed as we
run shutil.rmtree before.
Change-Id: I555c6d55ee1e288767192f83408a1f132544c928
---
M scripts/osmotestconfig.py
1 file changed, 13 insertions(+), 4 deletions(-)
diff --git a/scripts/osmotestconfig.py b/scripts/osmotestconfig.py
index d2d1f03..d6521ff 100755
--- a/scripts/osmotestconfig.py
+++ b/scripts/osmotestconfig.py
@@ -71,10 +71,7 @@
if os.path.exists(dirname):
shutil.rmtree(dirname)
- try:
- os.stat(dirname)
- except OSError:
- os.mkdir(dirname)
+ os.mkdir(dirname)
prefix = os.path.basename(config)
tmpfile = tempfile.NamedTemporaryFile(
To view, visit change 36938. To unsubscribe, or for help writing mail filters, visit settings.