[analyzer] [tests] Create a directory for the log file
llvm-svn: 326408
diff --git a/clang/utils/analyzer/SATestUpdateDiffs.py b/clang/utils/analyzer/SATestUpdateDiffs.py
index 8cda8d1..92bbd83 100755
--- a/clang/utils/analyzer/SATestUpdateDiffs.py
+++ b/clang/utils/analyzer/SATestUpdateDiffs.py
@@ -35,6 +35,8 @@
sys.exit(1)
BuildLogPath = SATestBuild.getBuildLogPath(RefResultsPath)
+ Dirname = os.path.dirname(os.path.abspath(BuildLogPath))
+ runCmd("mkdir -p '%s'" % Dirname)
with open(BuildLogPath, "wb+") as PBuildLogFile:
# Remove reference results: in git, and then again for a good measure
# with rm, as git might not remove things fully if there are empty