| INT WINAPI InetGetStatus( |
| |
SOCKET hSocket |
|
| ); |
The InetGetStatus function is used to report what sort of
socket operation is in progress.
Parameters
- hSocket
- The socket handle.
Return Value
If the function succeeds, the return value is the client status
code. If the function fails, the return value is INET_ERROR. To get
extended error information, call InetGetLastError.
Remarks
The return value is one of the following values:
| Value |
Constant |
Description |
| 0 |
INET_STATUS_UNUSED |
No connection has been established. |
| 1 |
INET_STATUS_IDLE |
The socket is idle and not in a blocked state |
| 2 |
INET_STATUS_LISTEN |
The socket is listening for inbound connections from a
client |
| 3 |
INET_STATUS_CONNECT |
The socket is establishing a connection with a server |
| 4 |
INET_STATUS_ACCEPT |
The socket is accepting a connection from a client |
| 5 |
INET_STATUS_READ |
Data is being read from the socket |
| 6 |
INET_STATUS_WRITE |
Data is being written to the socket |
| 7 |
INET_STATUS_FLUSH |
The socket is being flushed; all data in the receive buffers
is being discarded |
| 8 |
INET_STATUS_DISCONNECT |
The socket is disconnecting from the remote host |
In a multithreaded application, any thread in the current process
may call this function to obtain status information for the specified
socket.
Requirements
Minimum Desktop Platform: Windows 7 (Service Pack 1)
Minimum Server Platform: Windows Server 2008 R2 (Service Pack 1)
Header: Include cswsock10.h
Import Library: cswskv10.lib
See Also
InetGetBlockingSocket,
InetIsConnected,
InetIsListening,
InetIsReadable,
InetIsWritable
|