GetTempFileName: check for ERROR_SHARING_VIOLATION.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Force "FILE_GetTempFileName" to continue looking for new temp
file name if error returned from "CreateFileW" is ERROR_SHARING_VIOLATION.

--

Phil Mason
Software Development Engineer
Ricardo Consulting Engineers Ltd

Email - pmason@ricardo.com
Tel   -	work   	      	   01273-794914

diff -urN wine-20030508-old/files/file.c wine-20030508-new/files/file.c
--- wine-20030508-old/files/file.c	Tue Apr 22 05:04:17 2003
+++ wine-20030508-new/files/file.c	Thu May 15 17:15:19 2003
@@ -1090,7 +1090,8 @@
                 CloseHandle( handle );
                 break;
             }
-            if (GetLastError() != ERROR_FILE_EXISTS)
+            if (GetLastError() != ERROR_FILE_EXISTS) &&
+                GetLastError() != ERROR_SHARING_VIOLATION)
                 break;  /* No need to go on */
             num++;
             sprintf( buf, "%04x.tmp", num );

[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux