ruby-changes:23885
From: usa <ko1@a...>
Date: Wed, 6 Jun 2012 13:19:06 +0900 (JST)
Subject: [ruby-changes:23885] usa:r35936 (trunk): * win32/win32.c (rb_w32_close): of course, console handle is not socket.
usa 2012-06-06 13:18:53 +0900 (Wed, 06 Jun 2012) New Revision: 35936 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=35936 Log: * win32/win32.c (rb_w32_close): of course, console handle is not socket. Modified files: trunk/ChangeLog trunk/win32/win32.c Index: ChangeLog =================================================================== --- ChangeLog (revision 35935) +++ ChangeLog (revision 35936) @@ -1,3 +1,7 @@ +Wed Jun 6 13:18:26 2012 NAKAMURA Usaku <usa@r...> + + * win32/win32.c (rb_w32_close): of course, console handle is not socket. + Wed Jun 6 12:37:43 2012 NAKAMURA Usaku <usa@r...> * process.c (rb_run_exec_options_err): allocate a temporary buffer for Index: win32/win32.c =================================================================== --- win32/win32.c (revision 35935) +++ win32/win32.c (revision 35936) @@ -3062,6 +3062,8 @@ return r; } +#undef getsockopt + /* License: Artistic or GPL */ int WSAAPI rb_w32_getsockopt(int s, int level, int optname, char *optval, int *optlen) @@ -5902,11 +5904,11 @@ if (!is_socket(sock)) { UnlockFile((HANDLE)sock, 0, 0, LK_LEN, LK_LEN); + constat_delete((HANDLE)sock); return _close(fd); } _set_osfhnd(fd, (SOCKET)INVALID_HANDLE_VALUE); socklist_delete(&sock, NULL); - constat_delete((HANDLE)sock); _close(fd); errno = save_errno; if (closesocket(sock) == SOCKET_ERROR) { @@ -6630,12 +6632,14 @@ return numaddr; } +/* License: Ruby's */ char rb_w32_fd_is_text(int fd) { return _osfile(fd) & FTEXT; } #if RUBY_MSVCRT_VERSION < 80 +/* License: Ruby's */ static int unixtime_to_systemtime(const time_t t, SYSTEMTIME *st) { @@ -6645,6 +6649,7 @@ return 0; } +/* License: Ruby's */ static void systemtime_to_tm(const SYSTEMTIME *st, struct tm *t) { @@ -6670,6 +6675,7 @@ t->tm_yday = d - 1; } +/* License: Ruby's */ static int systemtime_to_localtime(TIME_ZONE_INFORMATION *tz, SYSTEMTIME *gst, SYSTEMTIME *lst) { @@ -6694,6 +6700,7 @@ } #endif +/* License: Ruby's */ struct tm * gmtime_r(const time_t *tp, struct tm *rp) { @@ -6717,6 +6724,7 @@ return rp; } +/* License: Ruby's */ struct tm * localtime_r(const time_t *tp, struct tm *rp) { -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/