[PATCH] D17903: Improve reliability of file renaming in Windows

Douglas Yung via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 20 01:12:00 PDT 2016

dyung added inline comments.

Comment at: lib/Support/Windows/Path.inc:281
@@ +280,3 @@
+          ReplaceError == ERROR_UNABLE_TO_MOVE_REPLACEMENT_2) {
+        TryReplace = false;
+        continue;
We felt that this situation was not possible in this case since we call ReplaceFileW with NULL as the value for lpBackupFileName, so we felt that no backup file would be made. Because of that, if this error occurs, we thought the result would be the same as the ERROR_UNABLE_TO_MOVE_REPLACEMENT, so we would handle it the same way.


More information about the llvm-commits mailing list