Merge remote branch 'trondn/master'

This commit is contained in:
Nick Mathewson 2010-10-27 10:27:04 -04:00
commit e8a903cee8

View File

@ -266,8 +266,11 @@ evutil_make_socket_nonblocking(evutil_socket_t fd)
{ {
#ifdef WIN32 #ifdef WIN32
{ {
unsigned long nonblocking = 1; u_long nonblocking = 1;
ioctlsocket(fd, FIONBIO, (unsigned long*) &nonblocking); if (ioctlsocket(fd, FIONBIO, &nonblocking) == SOCKET_ERROR) {
event_warn("fcntl(%d, F_GETFL)", (int)fd);
return -1;
}
} }
#else #else
{ {