<p dir="ltr">BTW, do you think we can drop the sleep? </p>
<div class="gmail_quote">On Apr 10, 2015 1:26 PM, "Reid Kleckner" <<a href="mailto:reid@kleckner.net">reid@kleckner.net</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: rnk<br>
Date: Fri Apr 10 12:20:45 2015<br>
New Revision: 234611<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=234611&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=234611&view=rev</a><br>
Log:<br>
[FS] Report errors from llvm::sys::fs::rename on Windows<br>
<br>
Previously we would always report success, which is pretty bogus.<br>
<br>
I'm too lazy to write a test where rename will portably fail on all<br>
platforms. I'm just trying to fix breakage introduced by r234597, which<br>
happened to tickle this.<br>
<br>
Modified:<br>
    llvm/trunk/lib/Support/Windows/Path.inc<br>
<br>
Modified: llvm/trunk/lib/Support/Windows/Path.inc<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/Windows/Path.inc?rev=234611&r1=234610&r2=234611&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/Windows/Path.inc?rev=234611&r1=234610&r2=234611&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/Support/Windows/Path.inc (original)<br>
+++ llvm/trunk/lib/Support/Windows/Path.inc Fri Apr 10 12:20:45 2015<br>
@@ -261,6 +261,7 @@ std::error_code rename(const Twine &from<br>
                       MOVEFILE_COPY_ALLOWED | MOVEFILE_REPLACE_EXISTING))<br>
       return std::error_code();<br>
     DWORD LastError = ::GetLastError();<br>
+    ec = windows_error(LastError);<br>
     if (LastError != ERROR_ACCESS_DENIED)<br>
       break;<br>
     // Retry MoveFile() at ACCESS_DENIED.<br>
<br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</blockquote></div>