diff options
Diffstat (limited to 'man3')
| -rw-r--r-- | man3/err.3 | 14 | ||||
| -rw-r--r-- | man3/fts.3 | 28 | ||||
| -rw-r--r-- | man3/queue.3 | 86 | ||||
| -rw-r--r-- | man3/rcmd.3 | 18 | ||||
| -rw-r--r-- | man3/rexec.3 | 8 | ||||
| -rw-r--r-- | man3/stdin.3 | 12 |
6 files changed, 89 insertions, 77 deletions
diff --git a/man3/err.3 b/man3/err.3 index fc1394a31d..c08db95dee 100644 --- a/man3/err.3 +++ b/man3/err.3 @@ -34,7 +34,7 @@ .\" .\" 2007-12-08, mtk, Converted from mdoc to man macros .\" -.TH ERR 3 2007-12-08 "Linux" "Linux Programmer's Manual" +.TH ERR 3 2007-12-28 "Linux" "Linux Programmer's Manual" .SH NAME err, verr, errx, verrx, warn, vwarn, warnx, vwarnx \- formatted error messages .SH SYNOPSIS @@ -74,7 +74,7 @@ argument is not NULL, the .BR printf (3)-like formatted error message is output. The output is terminated by a newline character. -.sp +.PP The .BR err (), .BR verr (), @@ -89,7 +89,7 @@ preceded by another colon and space unless the .I fmt argument is NULL. -.sp +.PP The .BR err (), .BR verr (), @@ -99,13 +99,13 @@ and functions use the global variable .I errno to look up the error message. -.sp +.PP The .BR errx () and .BR warnx () functions do not append an error message. -.sp +.PP The .BR err (), .BR verr (), @@ -125,7 +125,7 @@ if ((fd = open(file_name, O_RDONLY, 0)) == \-1) err(1, "%s", file_name); .fi .in -.sp +.PP Display an error message and exit: .in +4n .nf @@ -134,7 +134,7 @@ if (tm.tm_hour < START_TIME) errx(1, "too early, wait until %s", start_time_string); .fi .in -.sp +.PP Warn of an error: .in +4n .nf diff --git a/man3/fts.3 b/man3/fts.3 index 58c8e1923d..e101e06d22 100644 --- a/man3/fts.3 +++ b/man3/fts.3 @@ -35,7 +35,7 @@ .\" .\" 2007-12-08, mtk, Converted from mdoc to man macros .\" -.TH FTS 3 2007-12-08 "Linux" "Linux Programmer's Manual" +.TH FTS 3 2007-12-28 "Linux" "Linux Programmer's Manual" .SH NAME fts, fts_open, fts_read, fts_children, fts_set, fts_close \- \ traverse a file hierarchy @@ -80,7 +80,7 @@ Files are visited once. It is possible to walk the hierarchy "logically" (ignoring symbolic links) or physically (visiting symbolic links), order the walk of the hierarchy or prune and/or re-visit portions of the hierarchy. -.sp +.PP Two structures are defined (and typedef'd) in the include file .IR <fts.h> . The first is @@ -122,7 +122,7 @@ typedef struct _ftsent { } FTSENT; .fi .in -.sp +.PP These fields are defined as follows: .\" .Bl -tag -width "fts_namelen" .TP 12 @@ -371,7 +371,7 @@ or more paths which make up a logical file hierarchy to be traversed. The array must be terminated by a NULL pointer. -.sp +.PP There are a number of options, at least one of which (either .BR FTS_LOGICAL @@ -477,7 +477,7 @@ This option prevents fts from descending into directories that have a different device number than the file from which the descent began. .\" .El -.sp +.PP The argument .BR compar () specifies a user-defined function which may be used to order the traversal @@ -529,7 +529,7 @@ All other files are visited at least once. (Hard links between directories that do not cause cycles or symbolic links to symbolic links may cause files to be visited more than once, or directories more than twice.) -.sp +.PP If all the members of the hierarchy have been returned, .BR fts_read () returns @@ -550,7 +550,7 @@ structure is returned, and .I errno may or may not have been set (see .IR fts_info ). -.sp +.PP The .I FTSENT structures returned by @@ -585,7 +585,7 @@ structure, and is ordered by the user-specified comparison function, if any. Repeated calls to .BR fts_children () will recreate this linked list. -.sp +.PP As a special case, if .BR fts_read () has not yet been called for a hierarchy, @@ -613,7 +613,7 @@ NULL and sets .I errno appropriately. -.sp +.PP The .I FTSENT structures returned by @@ -624,7 +624,7 @@ may be overwritten after a call to or .BR fts_read () on the same file hierarchy stream. -.sp +.PP .I Option may be set to the following value: .\" .Bl -tag -width FTS_NAMEONLY @@ -699,7 +699,7 @@ fields of the returned structure will be unchanged and the .I fts_info field will be set to .BR FTS_SLNONE . -.sp +.IP If the target of the link is a directory, the pre-order return, followed by the return of all of its descendants, followed by a post-order return, is done. @@ -733,7 +733,7 @@ for any of the errors specified for .BR open (2) and .BR malloc (3). -.sp +.PP The function .BR fts_close () may fail and set @@ -742,7 +742,7 @@ for any of the errors specified for .BR chdir (2) and .BR close (2). -.sp +.PP The functions .BR fts_read () and @@ -756,7 +756,7 @@ for any of the errors specified for .BR readdir (3) and .BR stat (2). -.sp +.PP In addition, .BR fts_children (), .BR fts_open () diff --git a/man3/queue.3 b/man3/queue.3 index 84b28ee1a9..08485d0007 100644 --- a/man3/queue.3 +++ b/man3/queue.3 @@ -34,7 +34,7 @@ .\" hch, 2002-03-25 .\" 2007-12-08, mtk, Converted from mdoc to man macros .\" -.TH QUEUE 3 2007-12-08 "Linux" "Linux Programmer's Manual" +.TH QUEUE 3 2007-12-28 "Linux" "Linux Programmer's Manual" .SH NAME LIST_ENTRY, LIST_HEAD, LIST_INIT, LIST_INSERT_AFTER, \ LIST_INSERT_HEAD, LIST_REMOVE, TAILQ_ENTRY, TAILQ_HEAD, \ @@ -85,28 +85,33 @@ CIRCLEQ_REMOVE \- implementations of lists, tail queues, and circular queues These macros define and operate on three types of data structures: lists, tail queues, and circular queues. All three structures support the following functionality: -.RS -.IP 1. 4 +.sp +.RS 4 +.PD 0 +.IP * 4 Insertion of a new entry at the head of the list. -.IP 2. +.IP * Insertion of a new entry after any element in the list. -.IP 3. +.IP * Removal of any entry in the list. -.IP 4. +.IP * Forward traversal through the list. +.PD .RE .PP Lists are the simplest of the three data structures and support only the above functionality. Tail queues add the following functionality: -.RS -.IP 1. 4 +.RS 4 +.IP * 4 Entries can be added at the end of a list. .RE .PP However: -.RS +.sp +.RS 4 +.PD 0 .IP 1. 4 All list insertions and removals must specify the head of the list. .IP 2. @@ -114,20 +119,26 @@ Each head entry requires two pointers rather than one. .IP 3. Code size is about 15% greater and operations run about 20% slower than lists. +.PD .RE .PP Circular queues add the following functionality: -.RS -.IP 1. 4 +.sp +.RS 4 +.PD 0 +.IP * 4 Entries can be added at the end of a list. -.IP 2. +.IP * Entries can be added before another entry. -.IP 3. +.IP * They may be traversed backwards, from tail to head. +.PD .RE .PP However: -.RS +.sp +.RS 4 +.PD 0 .IP 1. 4 All list insertions and removals must specify the head of the list. .IP 2. @@ -137,6 +148,7 @@ The termination condition for traversal is more complex. .IP 4. Code size is about 40% greater and operations run about 45% slower than lists. +.PD .RE .PP In the macro definitions, @@ -177,7 +189,7 @@ structure is declared as follows: LIST_HEAD(HEADNAME, TYPE) head; .fi .in -.sp +.PP where .I HEADNAME is the name of the structure to be defined, and @@ -190,36 +202,36 @@ A pointer to the head of the list can later be declared as: struct HEADNAME *headp; .fi .in -.sp +.PP (The names .IR "head" and .IR "headp" are user selectable.) -.sp +.PP The macro .B LIST_ENTRY declares a structure that connects the elements in the list. -.sp +.PP The macro .B LIST_INIT initializes the list referenced by .IR head . -.sp +.PP The macro .B LIST_INSERT_HEAD inserts the new element .I elm at the head of the list. -.sp +.PP The macro .B LIST_INSERT_AFTER inserts the new element .I elm after the element .IR listelm . -.sp +.PP The macro .B LIST_REMOVE removes the element @@ -281,42 +293,42 @@ A pointer to the head of the tail queue can later be declared as: struct HEADNAME *headp; .fi .in -.sp +.PP (The names .IR "head" and .IR "headp" are user selectable.) -.sp +.PP The macro .B TAILQ_ENTRY declares a structure that connects the elements in the tail queue. -.sp +.PP The macro .B TAILQ_INIT initializes the tail queue referenced by .IR head . -.sp +.PP The macro .B TAILQ_INSERT_HEAD inserts the new element .I elm at the head of the tail queue. -.sp +.PP The macro .B TAILQ_INSERT_TAIL inserts the new element .I elm at the end of the tail queue. -.sp +.PP The macro .B TAILQ_INSERT_AFTER inserts the new element .I elm after the element .IR listelm . -.sp +.PP The macro .B TAILQ_REMOVE removes the element @@ -369,7 +381,7 @@ structure is declared as follows: CIRCLEQ_HEAD(HEADNAME, TYPE) head; .fi .in -.sp +.PP where .IR "HEADNAME" is the name of the structure to be defined, and @@ -382,49 +394,49 @@ A pointer to the head of the circular queue can later be declared as: struct HEADNAME *headp; .fi .in -.sp +.PP (The names .IR "head" and .IR "headp" are user selectable.) -.sp +.PP The macro .B CIRCLEQ_ENTRY declares a structure that connects the elements in the circular queue. -.sp +.PP The macro .B CIRCLEQ_INIT initializes the circular queue referenced by .IR head . -.sp +.PP The macro .B CIRCLEQ_INSERT_HEAD inserts the new element .I elm at the head of the circular queue. -.sp +.PP The macro .B CIRCLEQ_INSERT_TAIL inserts the new element .I elm at the end of the circular queue. -.sp +.PP The macro .B CIRCLEQ_INSERT_AFTER inserts the new element .I elm after the element .IR listelm . -.sp +.PP The macro .B CIRCLEQ_INSERT_BEFORE inserts the new element .I elm before the element .IR listelm . -.sp +.PP The macro .B CIRCLEQ_REMOVE removes the element diff --git a/man3/rcmd.3 b/man3/rcmd.3 index a5ee4e74c3..350b1c1ebc 100644 --- a/man3/rcmd.3 +++ b/man3/rcmd.3 @@ -38,7 +38,7 @@ .\" .\" 2007-12-08, mtk, Converted from mdoc to man macros .\" -.TH RCMD 3 2007-12-14 "Linux" "Linux Programmer's Manual" +.TH RCMD 3 2007-12-28 "Linux" "Linux Programmer's Manual" .SH NAME rcmd, rresvport, iruserok, ruserok \- routines for returning a stream to a remote command @@ -90,7 +90,7 @@ All four functions are present in the same file and are used by the .BR rshd (8) server (among others). -.sp +.PP The .BR rcmd () function @@ -105,7 +105,7 @@ is set to the standard name of the host and a connection is established to a server residing at the well-known Internet port .IR inport . -.sp +.PP If the connection succeeds, a socket in the Internet domain of type .BR SOCK_STREAM @@ -134,10 +134,10 @@ command) will be made the same as the and no provision is made for sending arbitrary signals to the remote process, although you may be able to get its attention by using out-of-band data. -.sp +.PP The protocol is described in detail in .BR rshd (8). -.sp +.PP The .BR rresvport () function is used to obtain a socket with a privileged @@ -147,7 +147,7 @@ This socket is suitable for use by and several other functions. Privileged Internet ports are those in the range 0 to 1023. Only the superuser is allowed to bind an address of this sort to a socket. -.sp +.PP The .BR iruserok () and @@ -164,7 +164,7 @@ If that lookup is not done, or is unsuccessful, the .IR .rhosts in the local user's home directory is checked to see if the request for service is allowed. -.sp +.PP If this file does not exist, is not a regular file, is owned by anyone other than the user or the superuser, or is writable by anyone other than the owner, the check automatically fails. @@ -180,7 +180,7 @@ return \-1. If the local domain (as obtained from .BR gethostname (2) is the same as the remote domain, only the machine name need be specified. -.sp +.PP If the IP address of the remote host is known, .BR iruserok () should be used in preference to @@ -192,7 +192,7 @@ The function returns a valid socket descriptor on success. It returns \-1 on error and prints a diagnostic message on the standard error. -.sp +.PP The .BR rresvport () function diff --git a/man3/rexec.3 b/man3/rexec.3 index e3c3ef063b..f7faa108e7 100644 --- a/man3/rexec.3 +++ b/man3/rexec.3 @@ -36,7 +36,7 @@ .\" .\" 2007-12-08, mtk, Converted from mdoc to man macros .\" -.TH REXEC 3 2007-12-08 "Linux" "Linux Programmer's Manual" +.TH REXEC 3 2007-12-28 "Linux" "Linux Programmer's Manual" .SH NAME rexec \- return stream to a remote command .SH SYNOPSIS @@ -68,7 +68,7 @@ the environment and then the user's file in his home directory are searched for appropriate information. If all this fails, the user is prompted for the information. -.sp +.PP The port .I inport specifies which well-known DARPA Internet port to use for @@ -79,7 +79,7 @@ the connection; the call will return a pointer to a structure that contains the necessary port. The protocol for connection is described in detail in .BR rexecd (8). -.sp +.PP If the connection succeeds, a socket in the Internet domain of type .BR SOCK_STREAM @@ -125,7 +125,7 @@ function appeared in The .BR rexec () function sends the unencrypted password across the network. -.sp +.PP The underlying service is considered a big security hole and therefore not enabled on many sites, see .BR rexecd (8) diff --git a/man3/stdin.3 b/man3/stdin.3 index 570827a74c..8465b44646 100644 --- a/man3/stdin.3 +++ b/man3/stdin.3 @@ -6,7 +6,7 @@ .\" .\" 2007-12-08, mtk, Converted from mdoc to man macros .\" -.TH STDIN 3 2007-12-08 "Linux" "Linux Programmer's Manual" +.TH STDIN 3 2007-12-28 "Linux" "Linux Programmer's Manual" .SH NAME stdin, stdout, stderr \- standard I/O streams .SH SYNOPSIS @@ -27,7 +27,7 @@ the user's terminal (see but might instead refer to files or other devices, depending on what the parent process chose to set up. (See also the "Redirection" section of .BR sh (1).) -.sp +.PP The input stream is referred to as "standard input"; the output stream is referred to as "standard output"; and the error stream is referred to as "standard error". @@ -46,7 +46,7 @@ and can be used with functions like .BR fprintf (3) or .BR fread (3). -.sp +.PP Since .IR FILE s are a buffering wrapper around Unix file descriptors, the @@ -55,7 +55,7 @@ interface, that is, the functions like .BR read (2) and .BR lseek (2). -.sp +.PP On program startup, the integer file descriptors associated with the streams .IR stdin , @@ -74,7 +74,7 @@ are defined with these values in .BR freopen (3) to one of these streams can change the file descriptor number associated with the stream.) -.sp +.PP Note that mixing use of .IR FILE s and raw file descriptors can produce @@ -87,7 +87,7 @@ This means for example, that after an .BR exec (3), the child inherits all open file descriptors, but all old streams have become inaccessible. -.sp +.PP Since the symbols .IR stdin , .IR stdout , |
