[ Team LiB ] Previous Section Next Section

9.12 sctp_peeloff Function

As previously mentioned, it is possible to extract an association contained by a one-to-many socket into an individual one-to-one-style socket. The semantics are much like the accept function call with an additional argument. The caller passes the sockfd of the one-to-many socket and the association identification id that is being extracted. At the completion of the call, a new socket descriptor is returned. This new descriptor will be a one-to-one-style socket descriptor with the requested association. The function takes the following form:

int sctp_peeloff(int sockfd, sctp_assoc_t id);

Returns: a new socket descriptor on success, –1 on error

    [ Team LiB ] Previous Section Next Section