Kaydet (Commit) c67d285a authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Intermediate dir may come into existence during osl_createDirectoryPath

...when some other entity creates it in parallel.  This used to stop creating
any subsequent sub-directories in the chain, and instead return a misleading
osl_File_E_EXIST.

I assume this is the underlying issue of the sporadic Jenkins "Daily Screenshot
Build on Windows" failures.  (After the previous attempt at getting at that,
d15ff312 "Normalize computation of directory and
file-in-directory URLs",
<https://ci.libreoffice.org/job/lo_tb_master_win_screenshot/333/console> now
failed for a different file after all,
workdir/screenshots/modules/schart/ui/datarangedialog/DataRangeDialog.png during
CppunitTest_chart2_dialogs_test.)

Change-Id: I00ee67c1ef634c5390c677693e143c26266eeda7
Reviewed-on: https://gerrit.libreoffice.org/50892Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarStephan Bergmann <sbergman@redhat.com>
üst a9ac68b7
......@@ -537,7 +537,7 @@ static oslFileError create_dir_recursively_(
oslFileError osl_error = create_dir_recursively_(
dir_path, aDirectoryCreationCallbackFunc, pData);
if (osl_error != osl_File_E_None)
if (osl_error != osl_File_E_None && osl_error != osl_File_E_EXIST)
return osl_error;
dir_path[pos] = '/';
......
......@@ -639,7 +639,7 @@ static DWORD create_dir_recursively_(
dir_path->buffer[pos] = BACKSLASH; // restore
if (ERROR_SUCCESS != w32_error)
if (ERROR_SUCCESS != w32_error && ERROR_ALREADY_EXISTS != w32_error)
return w32_error;
return create_dir_recursively_(dir_path, aDirectoryCreationCallbackFunc, pData);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment