diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | win32/win32.c | 2 |
2 files changed, 6 insertions, 1 deletions
@@ -1,3 +1,8 @@ +Mon Sep 28 19:36:20 2009 NAKAMURA Usaku <usa@ruby-lang.org> + + * win32/wini32.c (LK_ERR): with overlapped I/O, LockFileEx() returns + ERROR_IO_PENDING if the file is locked. + Mon Sep 28 19:05:05 2009 Martin Duerst <duerst@it.aoyama.ac.jp> * include/ruby/st.h: aligned prototype of st_hash_uint32 with function diff --git a/win32/win32.c b/win32/win32.c index 353873a22b..222af78c72 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -253,7 +253,7 @@ GetCurrentThreadHandle(void) i = 0; \ else { \ DWORD err = GetLastError(); \ - if (err == ERROR_LOCK_VIOLATION) \ + if (err == ERROR_LOCK_VIOLATION || err == ERROR_IO_PENDING) \ errno = EWOULDBLOCK; \ else if (err == ERROR_NOT_LOCKED) \ i = 0; \ |