Creates an ONC RPC server handle for a TCP/IP connection. Format #include <rpc/rpc.h> SVCXPRT *svctcp_create(int sock, u_int sendsize, u_int recvsize);
1 – Arguments
sock The socket with which the connection is associated. If sock is RPC_ANYSOCK, then this routine opens a new socket and sets sock. If the socket is not bound to a local TCP port, then this routine binds it to an arbitrary port. sendsize The size of the send buffer. If you specify zero, the routine chooses a suitable default. recvsize The size of the receive buffer. If you specify zero, the routine chooses a suitable default.
2 – Description
Creates an RPC server handle using the TCP/IP transport, to which it returns a pointer. Upon completion, xprt->xp_sock is the transport's socket descriptor, and xprt->xp_port is the transport's port number. The service is automatically registered as a transporter (thereby including its socket in svc_fds such that its socket descriptor is included in all RPC select system calls).
3 – Return Values
SVCXPRT * A pointer to the server handle. NULL Indicates failure.