while ((rv = recv( osfd, buf, amount, 0)) == -1)
if (0 == flags) { osflags = 0; } else { PR_ASSERT(PR_MSG_PEEK == flags); osflags = MSG_PEEK; } while ((rv = recv( osfd, buf, amount, osflags)) == -1)
_PR_MD_RECV(PRFileDesc *fd, void *buf, PRInt32 amount, PRIntn flags,             PRIntervalTime timeout){    PRInt32 osfd = fd->secret->md.osfd;    PRInt32 rv, err;    while ((rv = recv( osfd, buf, amount, 0)) == -1)     {        if (((err = WSAGetLastError()) == WSAEWOULDBLOCK)             && (!fd->secret->nonblocking))        {            rv = socket_io_wait(osfd, READ_FD, timeout);            if ( rv < 0 )            {                return -1;            }         }         else         {            _PR_MD_MAP_RECV_ERROR(err);            break;        }    } /* end while() */    return(rv);}