瀏覽代碼

[analyzer] [tests] Create a directory for the log file

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@326408 91177308-0d34-0410-b5e6-96231b3b80d8
George Karpenkov 7 年之前
父節點
當前提交
b7f026ae77
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      utils/analyzer/SATestUpdateDiffs.py

+ 2 - 0
utils/analyzer/SATestUpdateDiffs.py

@@ -35,6 +35,8 @@ def updateReferenceResults(ProjName, ProjBuildMode):
         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