diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-12-22 09:00:23 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-12-22 09:00:23 +0000 |
commit | e6bf7809f399b4602c9b3a2aa4761da0e336fb83 (patch) | |
tree | a423ef967d835ff2af929f5912a7c4b66f96166e /win32 | |
parent | 7f16734d2722ae0a33125bac9c9de5a90dba3e83 (diff) | |
download | ruby-e6bf7809f399b4602c9b3a2aa4761da0e336fb83.tar.gz |
matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'win32')
-rw-r--r-- | win32/Makefile.sub | 3 | ||||
-rw-r--r-- | win32/win32.c | 5 |
2 files changed, 6 insertions, 2 deletions
diff --git a/win32/Makefile.sub b/win32/Makefile.sub index 403f5453b1..227ab68b18 100644 --- a/win32/Makefile.sub +++ b/win32/Makefile.sub @@ -102,7 +102,7 @@ OBJS = array.obj \ all: miniruby$(EXEEXT) rbconfig.rb ext/extmk.rb \ $(LIBRUBY) $(MISCLIBS) - set LIB=../../win32;$(ORGLIBPATH) + set LIB=../..;$(ORGLIBPATH) @.\miniruby$(EXEEXT) -Cext extmk.rb ruby: $(PROGRAM) @@ -195,7 +195,6 @@ $(RUBY_INSTALL_NAME).rc $(RUBYW_INSTALL_NAME).rc $(LIBRUBY_SO).rc: rbconfig.rb $(CC) $(CFLAGS) -I. -I$(<D) $(CPPFLAGS) -c $(<:/=\) .c.obj: $(CC) $(CFLAGS) -I. $(CPPFLAGS) -c $(<:/=\) - $(CC) $(CFLAGS) $(CPPFLAGS) -c $< .rc.res: $(RC) -I. -I$(<D) -I$(srcdir)/win32 $(RFLAGS) -fo$@ $< diff --git a/win32/win32.c b/win32/win32.c index 22f3af9ed9..bd07bb644e 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -1974,6 +1974,11 @@ myselect (int nfds, fd_set *rd, fd_set *wr, fd_set *ex, if (!NtSocketsInitialized++) { StartSockets(); } + r = 0; + if (rd && rd->fd_count > r) r = rd->fd_count; + if (wr && wr->fd_count > r) r = wr->fd_count; + if (ex && ex->fd_count > r) r = ex->fd_count; + if (nfds > r) nfds = r; if (nfds == 0 && timeout) { Sleep(timeout->tv_sec * 1000 + timeout->tv_usec / 1000); return 0; |