PRInt32 _nt_nonblock_recv(PRFileDesc *fd, char *buf, int len, PRIntervalTime timeout)
PRInt32 _nt_nonblock_recv(PRFileDesc *fd, char *buf, int len, int flags, PRIntervalTime timeout)
PRInt32 _nt_nonblock_recv(PRFileDesc *fd, char *buf, int len, PRIntervalTime timeout){    PRInt32 osfd = fd->secret->md.osfd;    PRInt32 rv, err;    struct timeval tv, *tvp;    fd_set rd;    while ((rv = recv(osfd,buf,len,0)) == -1) {        if (((err = WSAGetLastError()) == WSAEWOULDBLOCK)                && (!fd->secret->nonblocking)) {            FD_ZERO(&rd);            FD_SET((SOCKET)osfd, &rd);            if (timeout == PR_INTERVAL_NO_TIMEOUT) {                tvp = NULL;            } else {                tv.tv_sec = PR_IntervalToSeconds(timeout);                tv.tv_usec = PR_IntervalToMicroseconds(                timeout - PR_SecondsToInterval(tv.tv_sec));                tvp = &tv;            }            if ((rv = _PR_NTFiberSafeSelect(osfd + 1, &rd, NULL, NULL,                    tvp)) == -1) {                _PR_MD_MAP_SELECT_ERROR(WSAGetLastError());                break;            } else if (rv == 0) {                PR_SetError(PR_IO_TIMEOUT_ERROR, 0);                rv = -1;                break;            }        } else {            _PR_MD_MAP_RECV_ERROR(err);            break;        }    }    return(rv);}