From 9cd498761479b4c3e1b95baf6c463de4f3426faa Mon Sep 17 00:00:00 2001 From: usa Date: Tue, 14 Dec 2004 08:10:32 +0000 Subject: * win32/win32.c (rb_w32_close): need to reset osfhnd(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@7552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- win32/win32.c | 1 + 1 file changed, 1 insertion(+) (limited to 'win32') diff --git a/win32/win32.c b/win32/win32.c index d4deec8d0a..1a859a5a3f 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -3223,6 +3223,7 @@ rb_w32_close(int fd) UnlockFile((HANDLE)sock, 0, 0, LK_LEN, LK_LEN); return _close(fd); } + _set_osfhnd(fd, (SOCKET)INVALID_HANDLE_VALUE); if (closesocket(sock) == SOCKET_ERROR) { errno = map_errno(WSAGetLastError()); return -1; -- cgit v1.2.3