soAccept (Function) |
Top Previous Next |
The soAccept function will accept the first pending connection attempt, if present, in the queue of a listening socket. A new socket will be created for the resulting connection.
On a blocking socket, the function will wait until an incoming connection attempt is received before returning. With a non-blocking socket, the function will return immediately if no pending connection attempts are present. In this case soAccept will return -4.
The socket must be marked as listening for incoming connections with the soListen function before calling this function.
Input: socket : SYSHANDLE Handle to the socket.
Output: remote : SYSHANDLE Handle to the new socket.
Returns: INT
Declaration: FUNCTION soAccept : INT;
Example:
|