|
nbsp; wshout_err
(hOurDlg, WSAGetLastError(), "bind()");
return
(SOCKET) -1;
}
if (iProto == iUDP)
return
(hSock);
/* If iProto == iTCP, then must listen() and accept() also */
ret = listen(hSock, 0); /* listen on the socket */
if (ret == SOCKET_ERROR){ /*
listen() failed */
wshout_err
(hOurDlg, WSAGetLastError(), "listen()");
return
(SOCKET) -1;
}
return(hSock);
}
/* eof */
|