summaryrefslogtreecommitdiffstats
path: root/win32
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-12-14 08:10:32 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-12-14 08:10:32 +0000
commit5b6de739640a4553e5d75631f9e0856e1918cf33 (patch)
tree93506fdb7938db7febac62e1155e0b21d7ca438b /win32
parent52c74c8a47c7303a63a60c4fe31936a093312def (diff)
downloadruby-5b6de739640a4553e5d75631f9e0856e1918cf33.tar.gz
ruby-5b6de739640a4553e5d75631f9e0856e1918cf33.tar.xz
ruby-5b6de739640a4553e5d75631f9e0856e1918cf33.zip
* win32/win32.c (rb_w32_close): need to reset osfhnd().
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@7552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'win32')
-rw-r--r--win32/win32.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/win32/win32.c b/win32/win32.c
index 5dafc0320..7a7078335 100644
--- a/win32/win32.c
+++ b/win32/win32.c
@@ -3421,6 +3421,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;