зеркало из https://github.com/github/ruby.git
* thread.c (rb_fd_rcopy): suppress warnings on mingw32.
* win32/win32.c (overlapped_socket_io, recvmsg, sendmsg, dupfd): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33621 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
b45c882aec
Коммит
ac46d76ce8
2
thread.c
2
thread.c
|
@ -2471,7 +2471,7 @@ rb_fd_rcopy(fd_set *dst, rb_fdset_t *src)
|
|||
|
||||
/* we assume src is the result of select() with dst, so dst should be
|
||||
* larger or equal than src. */
|
||||
if (max > FD_SETSIZE || max > dst->fd_count) {
|
||||
if (max > FD_SETSIZE || (UINT)max > dst->fd_count) {
|
||||
rb_raise(rb_eArgError, "too large fdsets");
|
||||
}
|
||||
|
||||
|
|
|
@ -3147,7 +3147,7 @@ overlapped_socket_io(BOOL input, int fd, char *buf, int len, int flags,
|
|||
{
|
||||
int r;
|
||||
int ret;
|
||||
int mode;
|
||||
int mode = 0;
|
||||
DWORD flg;
|
||||
WSAOVERLAPPED wol;
|
||||
WSABUF wbuf;
|
||||
|
@ -3282,7 +3282,7 @@ recvmsg(int fd, struct msghdr *msg, int flags)
|
|||
static WSARecvMsg_t pWSARecvMsg = NULL;
|
||||
WSAMSG wsamsg;
|
||||
SOCKET s;
|
||||
int mode;
|
||||
int mode = 0;
|
||||
DWORD len;
|
||||
int ret;
|
||||
|
||||
|
@ -3340,7 +3340,7 @@ sendmsg(int fd, const struct msghdr *msg, int flags)
|
|||
static WSASendMsg_t pWSASendMsg = NULL;
|
||||
WSAMSG wsamsg;
|
||||
SOCKET s;
|
||||
int mode;
|
||||
int mode = 0;
|
||||
DWORD len;
|
||||
int ret;
|
||||
|
||||
|
@ -3811,7 +3811,7 @@ dupfd(HANDLE hDup, char flags, int minfd)
|
|||
goto close_fds_and_return;
|
||||
}
|
||||
fds[filled++] = ret;
|
||||
} while (filled < (sizeof(fds)/sizeof(fds[0])));
|
||||
} while (filled < (int)numberof(fds));
|
||||
|
||||
ret = dupfd(hDup, flags, minfd);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче