Query: sctp_peeloff
OS: opensolaris
Section: 3socket
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
sctp_peeloff(3SOCKET) Sockets Library Functions sctp_peeloff(3SOCKET)NAMEsctp_peeloff - branch off existing association from a one-to-many SCTP socket to create a one-to-one STP socketSYNOPSIScc [ flag... ] file... -lsocket -lnsl -lsctp [ library... ] #include <sys/types.h> #include <sys/socket.h> #include <netinet/sctp.h> int sctp_peeloff(int sock, sctp_assoc_t id);DESCRIPTIONThe sctp_peeloff() function branches off an existing association from a one-to-many style SCTP socket into a separate socket file descrip- tor. The resulting branched-off socket is a one-to-one style SCTP socket and is confined to operations allowed on a one-to-one style SCTP socket. The sock argument is a one-to-many socket. The association specified by the id argument is branched off sock.RETURN VALUESUpon successful completion, the sctp_peeloff() function returns the file descriptor that references the branched-off socket. The function returns -1 if an error occurs.ERRORSThe sctp_peeloff() function fails under the following conditions. EOPTNOTSUPP The sock argument is not a one-to-many style SCTP socket. EINVAL The id is 0 or greater than the maximum number of associations for sock. EMFILE Failure to create a new user file descriptor or file structure.ATTRIBUTESSee attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Evolving | +-----------------------------+-----------------------------+ |MT-Level |Safe | +-----------------------------+-----------------------------+SEE ALSOin.h(3HEAD), libsctp(3LIB), socket(3SOCKET), sctp(7P) SunOS 5.11 05 Mar 2004 sctp_peeloff(3SOCKET)