summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--eval.c4
2 files changed, 9 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index c50120a313..af4e697bf5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Wed Feb 25 22:53:04 2009 NAKAMURA Usaku <[email protected]>
+
+ * eval.c (rb_thread_schedule): mswin32 doesn't have F_GETFD, so check
+ with another method.
+
Tue Feb 24 19:01:05 2009 Nobuyoshi Nakada <[email protected]>
* common.mk (main): split from exts and makes main program after
diff --git a/eval.c b/eval.c
index 7092e61865..a06974657f 100644
--- a/eval.c
+++ b/eval.c
@@ -11193,7 +11193,11 @@ rb_thread_schedule()
if ((FD_ISSET(fd, &readfds) ||
FD_ISSET(fd, &writefds) ||
FD_ISSET(fd, &exceptfds)) &&
+#ifndef _WIN32
fcntl(fd, F_GETFD, &dummy) == -1 &&
+#else
+ rb_w32_get_osfhandle(fd) == -1 &&
+#endif
errno == EBADF) {
badfd = fd;
break;