1<sys/ipc.h>(0P) POSIX Programmer's Manual <sys/ipc.h>(0P)
2
3
4
6 sys/ipc.h - XSI interprocess communication access structure
7
9 #include <sys/ipc.h>
10
12 The <sys/ipc.h> header is used by three mechanisms for XSI interprocess
13 communication (IPC): messages, semaphores, and shared memory. All use a
14 common structure type, ipc_perm, to pass information used in determinā
15 ing permission to perform an IPC operation.
16
17 The ipc_perm structure shall contain the following members:
18
19
20 uid_t uid Owner's user ID.
21 gid_t gid Owner's group ID.
22 uid_t cuid Creator's user ID.
23 gid_t cgid Creator's group ID.
24 mode_t mode Read/write permission.
25
26 The uid_t, gid_t, mode_t, and key_t types shall be defined as described
27 in <sys/types.h> .
28
29 Definitions shall be provided for the following constants:
30
31 Mode bits:
32
33 IPC_CREAT
34 Create entry if key does not exist.
35
36 IPC_EXCL
37 Fail if key exists.
38
39 IPC_NOWAIT
40 Error if request must wait.
41
42
43 Keys:
44
45 IPC_PRIVATE
46 Private key.
47
48
49 Control commands:
50
51 IPC_RMID
52 Remove identifier.
53
54 IPC_SET
55 Set options.
56
57 IPC_STAT
58 Get options.
59
60
61 The following shall be declared as a function and may also be defined
62 as a macro. A function prototype shall be provided.
63
64
65 key_t ftok(const char *, int);
66
67 The following sections are informative.
68
70 None.
71
73 None.
74
76 None.
77
79 <sys/types.h>, the System Interfaces volume of IEEE Std 1003.1-2001,
80 ftok()
81
83 Portions of this text are reprinted and reproduced in electronic form
84 from IEEE Std 1003.1, 2003 Edition, Standard for Information Technology
85 -- Portable Operating System Interface (POSIX), The Open Group Base
86 Specifications Issue 6, Copyright (C) 2001-2003 by the Institute of
87 Electrical and Electronics Engineers, Inc and The Open Group. In the
88 event of any discrepancy between this version and the original IEEE and
89 The Open Group Standard, the original IEEE and The Open Group Standard
90 is the referee document. The original Standard can be obtained online
91 at http://www.opengroup.org/unix/online.html .
92
93
94
95IEEE/The Open Group 2003 <sys/ipc.h>(0P)