1 .\" Copyright (c) [year] [your name]
2 .\" All rights reserved.
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 .\" Note: The date here should be updated whenever a non-trivial
28 .\" change is made to the manual page.
34 .Nd "example library function manual page"
36 .\" Note: list of available libraries is available in mdoc(7)
41 .Fn example "char *ptr" "int mode"
43 This is an example library function manual page for the
46 It is intended that this example can be used as a template
47 when writing a new manual page.
51 function takes two arguments:
57 may have one of the following values:
58 .Bl -tag -width ".Dv EXAMPLE_ONE"
60 First example of a defined variable.
67 The above values are defined in
74 .Sh IMPLEMENTATION NOTES
77 function is not actually implemented.
83 library function ignores the
87 .Bl -tag -width ".Pa /dev/null" -compact
89 Example of a file in the
98 function has no known compatibility issues.
100 .\" Delete any errno's that are not returned by your
101 .\" function or system call and then tailor the
102 .\" remaining text as needed.
105 function will fail if:
108 Operation not permitted.
110 No such file or directory.
114 Interrupted system call.
118 Device not configured.
120 Argument list too long.
128 Resource deadlock avoided.
130 Cannot allocate memory.
136 Block device required.
144 Operation not supported by device.
152 Too many open files in system.
156 Inappropriate ioctl for device.
162 No space left on device.
166 Read-only file system.
172 Numerical argument out of domain.
176 Resource temporarily unavailable.
177 .It Bq Er EWOULDBLOCK
178 Operation would block.
179 .It Bq Er EINPROGRESS
180 Operation now in progress.
182 Operation already in progress.
184 Socket operation on non-socket.
185 .It Bq Er EDESTADDRREQ
186 Destination address required.
190 Protocol wrong type for socket.
191 .It Bq Er ENOPROTOOPT
192 Protocol not available.
193 .It Bq Er EPROTONOSUPPORT
194 Protocol not supported.
195 .It Bq Er ESOCKTNOSUPPORT
196 Socket type not supported.
198 Operation not supported.
199 .It Bq Er EPFNOSUPPORT
200 Protocol family not supported.
201 .It Bq Er EAFNOSUPPORT
202 Address family not supported by protocol family.
204 Address already in use.
205 .It Bq Er EADDRNOTAVAIL
206 Cannot assign requested address.
209 .It Bq Er ENETUNREACH
210 Network is unreachable.
212 Network dropped connection on reset.
213 .It Bq Er ECONNABORTED
214 Software causes connection abort.
216 No buffer space available.
218 Socket is already connected.
220 Socket is not connected.
222 Cannot send after socket shutdown.
223 .It Bq Er ETOOMANYREFS
224 Too many references: cannot splice.
227 .It Bq Er ECONNREFUSED
230 Too many levels of symbolic links.
231 .It Bq Er ENAMETOOLONG
235 .It Bq Er EHOSTUNREACH
246 Stale NFS file handle.
248 Too many levels of remote in path.
251 .It Bq Er ERPCMISMATCH
253 .It Bq Er EPROGUNAVAIL
254 RPC program not available.
255 .It Bq Er EPROGMISMATCH
256 Program version wrong.
257 .It Bq Er EPROCUNAVAIL
258 Bad procedure for program.
262 Function not implemented.
264 Inappropriate file type or format.
266 Authentication error.
272 No message of desired type.
274 Value too large to be stored in data type.
278 Illegal byte sequence.
291 .%T "Example RFC Title"
296 .%B "Example Book Title"
297 .%O ISBN-0-000-00000-0
302 .%J "Example Journal Name"
303 .%T "Example Article Title"
306 If the function conforms to some standard, such as
310 it should be noted here.
314 manual page example first appeared in
319 section examples are:
323 manual page example first appeared in
328 manual page example first appeared in
332 manual page was written by
333 .An Mike Pritchard Aq mpp@FreeBSD.org .
335 The actual code for this function is vaporware.