t_accept - Accepts a connect request
XTI Library (libxti.a)
struct t_call *call) ;
Interfaces documented on this reference page conform to industry standards as follows:
Refer to the standards(5) reference page for more information about industry standards and associated tags.
The following table summarizes the relevance of input and output parameters before and after t_accept() is called:
|Parameter||Before Call||After Call|
y This is a meaningful parameter. n This is not a meaningful parameter. o This is an optional parameter. (o) The content of the object pointed to by o is optional.
The t_accept() function can only be called in the following transport provider states: For fd, T_INCON. For fd != resfd, T_IDLE or T_UNBND.
The t_accept() function is an XTI connection-oriented service function that is issued by a transport user to accept a connect request after a connect indication has arrived. Structures of types t_call and netbuf, which are defined in the xti.h include file, are used by this function.
Some transport providers do not distinguish between a connection indication and the connection itself. If the connection is already established after t_listen() returns 0 (success), t_accept() assigns the existing connection to the transport endpoint specified by resfd. See xti_internet(7) for more information.
Upon successful completion, a value of 0 (zero) is returned. Otherwise, a value of -1 is returned and t_errno is set to indicate the error.
If the t_accept() function fails, t_errno may be set to one of the following: The user does not have permission to accept a connection on the responding transport endpoint or to use the specified options. The specified protocol address was in an incorrect format or contained illegal information. The amount of user data specified was not within the bounds allowed by the transport provider. The fd or resfd file descriptor does not refer to a transport endpoint, or the user is illegally accepting a connection on the same transport endpoint on which the connect indication arrived. The specified options were in an incorrect format or contained illegal information. An invalid sequence number was specified. The function was called with identical fd and the resfd parameters, but the endpoint still has outstanding connection indications. You can either reject the connection indications with the t_snddis function or accept them on a different endpoint with the t_accept function. An asynchronous event has occurred on the transport endpoint referenced by the fd parameter and requires immediate attention. This function is not supported by the underlying transport provider. The t_accept() function was called in the wrong sequence at the transport endpoint referenced by the fd parameter, or the transport endpoint referred to by the resfd parameter is not in the appropriate state. The fd and the resfd parameters do not refer to the same transport provider. An unspecified communication problem has occurred between XTI and the transport provider. The fd and resfd parameters are not bound to the same address. The endpoint referenced by the resfd parameter, provided resfd does not equal fd, was bound to a protocol address with a qlen greater than zero. A system error occurred during execution of this function.
Functions: t_alloc(3), t_bind(3), t_connect(3), t_getstate(3), t_listen(3), t_open(3), t_optmgmt(3), t_rcvconnect(3).
Network Information: xti(7), xti_internet(7). delim off