Platform SDK: Windows Sockets |
The WPUCloseSocketHandle function closes an existing socket handle.
int WPUCloseSocketHandle ( SOCKET s, LPINT lpErrno );
If no error occurs, WPUCreateSocketHandle returns zero. Otherwise, it returns SOCKET_ERROR, and a specific error code is available in lpErrno.
The WPUCloseSocketHandle function closes an existing socket handle created by WPUCreateSocketHandle. This function removes the socket from Ws2_32.dll's internal socket table. The owning service provider is responsible for releasing any resources associated with the socket.
Error code | Meaning |
---|---|
WSAENOTSOCK | Descriptor is not a socket created by WPUCreateSocketHandle. |
Version: Requires Windows Sockets 2.0.
Header: Declared in Ws2spi.h.