1sctp_peeloff(3SOCKET)      Sockets Library Functions     sctp_peeloff(3SOCKET)
2
3
4

NAME

6       sctp_peeloff  - branch off existing association from a one-to-many SCTP
7       socket to create a one-to-one STP socket
8

SYNOPSIS

10       cc [ flag... ] file... -lsocket  -lnsl   -lsctp  [ library... ]
11       #include <sys/types.h>
12       #include <sys/socket.h>
13       #include <netinet/sctp.h>
14
15       int sctp_peeloff(int sock, sctp_assoc_t id);
16
17

DESCRIPTION

19       The sctp_peeloff() function branches off an existing association from a
20       one-to-many  style  SCTP socket into a separate socket file descriptor.
21       The resulting branched-off socket is a one-to-one style SCTP socket and
22       is confined to operations allowed on a one-to-one style SCTP socket.
23
24
25       The sock argument is a one-to-many socket. The association specified by
26       the id argument is branched off sock.
27

RETURN VALUES

29       Upon successful completion, the  sctp_peeloff()  function  returns  the
30       file  descriptor  that references the branched-off socket. The function
31       returns -1 if an error occurs.
32

ERRORS

34       The sctp_peeloff() function fails under the following conditions.
35
36       EOPTNOTSUPP    The sock  argument  is  not  a  one-to-many  style  SCTP
37                      socket.
38
39
40       EINVAL         The  id is 0 or greater than the maximum number of asso‐
41                      ciations for sock.
42
43
44       EMFILE         Failure to create a new user  file  descriptor  or  file
45                      structure.
46
47

ATTRIBUTES

49       See attributes(5) for descriptions of the following attributes:
50
51
52
53
54       ┌─────────────────────────────┬─────────────────────────────┐
55       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
56       ├─────────────────────────────┼─────────────────────────────┤
57       │Interface Stability          │Evolving                     │
58       ├─────────────────────────────┼─────────────────────────────┤
59       │MT-Level                     │Safe                         │
60       └─────────────────────────────┴─────────────────────────────┘
61

SEE ALSO

63       in.h(3HEAD), libsctp(3LIB), socket(3SOCKET), sctp(7P)
64
65
66
67SunOS 5.11                        05 Mar 2004            sctp_peeloff(3SOCKET)
Impressum