Penguin
Annotated edit history of mkfifo(3) version 1, including all changes. View license author blame.
Rev Author # Line
1 perry 1 MKFIFO
2 !!!MKFIFO
3 NAME
4 SYNOPSIS
5 DESCRIPTION
6 RETURN VALUE
7 ERRORS
8 CONFORMING TO
9 SEE ALSO
10 ----
11 !!NAME
12
13
14 mkfifo - make a FIFO special file (a named pipe)
15 !!SYNOPSIS
16
17
18 __#include
19 __''pathname''__, mode_t__ ''mode'' __);
20 __
21 !!DESCRIPTION
22
23
24 __mkfifo__ makes a FIFO special file with name
25 ''pathname''. ''mode'' specifies the FIFO's
26 permissions. It is modified by the process's __umask__ in
27 the usual way: the permissions of the created file are
28 __(__''mode'' ____.
29
30
31 A FIFO special file is similar to a pipe, except that it is
32 created in a different way. Instead of being an anonymous
33 communications channel, a FIFO special file is entered into
34 the file system by calling __mkfifo__.
35
36
37 Once you have created a FIFO special file in this way, any
38 process can open it for reading or writing, in the same way
39 as an ordinary file. However, it has to be open at both ends
40 simultaneously before you can proceed to do any input or
41 output operations on it. Opening a FIFO for reading normally
42 blocks until some other process opens the same FIFO for
43 writing, and vice versa. See fifo(4) for non-blocking
44 handling of FIFO special files.
45 !!RETURN VALUE
46
47
48 The normal, successful return value from ''mkfifo'' is
49 __0__. In the case of an error, __-1__ is returned (in
50 which case, ''errno'' is set appropriately).
51 !!ERRORS
52
53
54 __EACCES__
55
56
57 One of the directories in ''pathname'' did not allow
58 search (execute) permission.
59
60
61 __EEXIST__
62
63
64 ''pathname'' already exists.
65
66
67 __ENAMETOOLONG__
68
69
70 Either the total length of ''pathname'' is greater than
71 __PATH_MAX__, or an individual file name component has a
72 length greater than __NAME_MAX__. In the GNU system,
73 there is no imposed limit on overall file name length, but
74 some file systems may place limits on the length of a
75 component.
76
77
78 __ENOENT__
79
80
81 A directory component in ''pathname'' does not exist or
82 is a dangling symbolic link.
83
84
85 __ENOSPC__
86
87
88 The directory or filesystem has no room for the new
89 file.
90
91
92 __ENOTDIR__
93
94
95 A component used as a directory in ''pathname'' is not,
96 in fact, a directory.
97
98
99 __EROFS__
100
101
102 ''pathname'' refers to a read-only
103 filesystem.
104 !!CONFORMING TO
105
106
107 POSIX.1
108 !!SEE ALSO
109
110
111 mkfifo(1), read(2), write(2),
112 open(2), close(2), stat(2),
113 umask(2), fifo(4)
114 ----
This page is a man page (or other imported legacy content). We are unable to automatically determine the license status of this page.