From 4ae914885a185ed0190ad2ac21a004e8b60af042 Mon Sep 17 00:00:00 2001 From: eban Date: Thu, 4 Oct 2001 05:32:09 +0000 Subject: * ext/socket/socket.c (ruby_connect): EALREADY is the equivalent for EINPROGRESS in ws2_32.lib. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@1766 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/socket/socket.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ext/socket') diff --git a/ext/socket/socket.c b/ext/socket/socket.c index 5b7d8ebef..8974096bb 100644 --- a/ext/socket/socket.c +++ b/ext/socket/socket.c @@ -747,6 +747,7 @@ ruby_connect(fd, sockaddr, len, socks) #ifdef EINPROGRESS case EINPROGRESS: #if defined __CYGWIN__ + case EALREADY: wait_in_progress = 10; #endif #endif @@ -754,9 +755,8 @@ ruby_connect(fd, sockaddr, len, socks) continue; #if defined __CYGWIN__ - case EALREADY: case EINVAL: - if (--wait_in_progress > 0) { + if (wait_in_progress-- > 0) { struct timeval tv = {0, 100000}; rb_thread_wait_for(tv); continue; -- cgit