浏览代码

* don't fail if multiple dotests try to create the same directory in parallel

git-svn-id: trunk@30220 -
Jonas Maebe 10 年之前
父节点
当前提交
f4a580d669
共有 1 个文件被更改,包括 7 次插入2 次删除
  1. 7 2
      tests/utils/dotest.pp

+ 7 - 2
tests/utils/dotest.pp

@@ -380,8 +380,13 @@ begin
       Err := IOResult;
       if Err <> 0 then
        begin
-        Str (Err, SErr);
-        Verbose (V_Error, 'Directory creation failed ' + SErr);
+        { did another parallel instance create it in the mean time? }
+        if not PathExists(hs) then
+          begin
+            { no -> error }
+            Str (Err, SErr);
+            Verbose (V_Error, 'Directory creation of "'+HS+'" failed ' + SErr);
+          end;
        end;
     end;
 end;