fcntl.2, ioctl_tty.2, kcmp.2, prctl.2, semop.2, swapon.2, atof.3, atoi.3, bsearch.3, cfree.3, ctime.3, drand48.3, errno.3: ffix

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2017-08-17 13:41:27 +02:00
parent 47f743f12e
commit ba39b288ab
13 changed files with 62 additions and 46 deletions

View File

@ -1196,8 +1196,8 @@ The events to be notified are specified in
.IR arg ,
which is a bit mask specified by ORing together zero or more of
the following bits:
.PP
.RS
.sp
.PD 0
.TP 12
.B DN_ACCESS

View File

@ -517,7 +517,7 @@ This command was removed in Linux 2.5.67.
.\"
.\" .SS Serial info
.\" .BR "#include <linux/serial.h>"
.\" .sp
.\" .PP
.\" .TP
.\" .BI "TIOCGSERIAL struct serial_struct *" argp
.\" Get serial info.

View File

@ -173,9 +173,9 @@ The argument
.I idx2
is a pointer to a structure where the target file is described.
This structure has the form:
.PP
.in +4n
.nf
.sp
struct kcmp_epoll_slot {
__u32 efd;
__u32 tfd;
@ -183,6 +183,7 @@ struct kcmp_epoll_slot {
};
.fi
.in
.PP
Within this structure,
.I efd
is an epoll file descriptor returned from

View File

@ -1575,9 +1575,13 @@ IRIX has a
system call (also introduced in Linux 2.1.44
as irix_prctl on the MIPS architecture),
with prototype
.sp
.PP
.in +4n
.EX
.BI "ptrdiff_t prctl(int " option ", int " arg2 ", int " arg3 );
.sp
.EE
.in
.PP
and options to get the maximum number of processes per user,
get the maximum number of processors the calling process can use,
find out whether a specified process is currently blocked,

View File

@ -86,9 +86,9 @@ containing the following members:
unsigned short sem_num; /* semaphore number */
short sem_op; /* semaphore operation */
short sem_flg; /* operation flags */
.sp
.in -4n
.fi
.PP
Flags recognized in
.I sem_flg
are

View File

@ -67,10 +67,12 @@ argument, the new swap area will have a higher priority than default.
The priority is encoded within
.I swapflags
as:
.br
.sp
.I " (prio << SWAP_FLAG_PRIO_SHIFT) & SWAP_FLAG_PRIO_MASK"
.br
.PP
.in +4n
.EX
.I "(prio << SWAP_FLAG_PRIO_SHIFT) & SWAP_FLAG_PRIO_MASK"
.EE
.in
.PP
If the
.B SWAP_FLAG_DISCARD

View File

@ -44,11 +44,13 @@ function converts the initial portion of the string
pointed to by \fInptr\fP to
.IR double .
The behavior is the same as
.sp
.PP
.in +4n
.EX
strtod(nptr, NULL);
.EE
.in
.sp
.PP
except that
.BR atof ()
does not detect errors.

View File

@ -63,11 +63,13 @@ function converts the initial portion of the string
pointed to by \fInptr\fP to
.IR int .
The behavior is the same as
.sp
.PP
.in +4n
.EX
strtol(nptr, NULL, 10);
.EE
.in
.sp
.PP
except that
.BR atoi ()
does not detect errors.

View File

@ -94,8 +94,8 @@ The example below first sorts an array of structures using
.BR qsort (3),
then retrieves desired elements using
.BR bsearch ().
.sp
.nf
.PP
.EX
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@ -137,7 +137,7 @@ main(int argc, char **argv)
}
exit(EXIT_SUCCESS);
}
.fi
.EE
.\" this example referred to in qsort.3
.SH SEE ALSO
.BR hsearch (3),

View File

@ -77,11 +77,13 @@ apparently as an analog to
.BR calloc (3).
.LP
If you need it while porting something, add
.sp
.PP
.in +4n
.EX
#define cfree(p, n, s) free((p))
.EE
.in
.sp
.PP
to your file.
.LP
A frequently asked question is "Can I use

View File

@ -95,9 +95,9 @@ separated into year, month, day, and so on.
.PP
Broken-down time is stored
in the structure \fItm\fP, which is defined in \fI<time.h>\fP as follows:
.sp
.PP
.in +4n
.nf
.EX
struct tm {
int tm_sec; /* Seconds (0-60) */
int tm_min; /* Minutes (0-59) */
@ -109,7 +109,7 @@ struct tm {
int tm_yday; /* Day in the year (0-365, 1 Jan = 0) */
int tm_isdst; /* Daylight saving time */
};
.fi
.EE
.in
.PP
The members of the \fItm\fP structure are:
@ -152,11 +152,14 @@ is equivalent to
.BI asctime(localtime( t )) \fR.
It converts the calendar time \fIt\fP into a
null-terminated string of the form
.sp
.PP
.in +4n
.EX
.RS
"Wed Jun 30 21:49:08 1993\\n"
.RE
.sp
.EE
,in
.PP
The abbreviations for the days of the week are "Sun", "Mon", "Tue", "Wed",
"Thu", "Fri", and "Sat".
The abbreviations for the months are "Jan",
@ -408,14 +411,14 @@ In many implementations, including glibc, a 0 in
is interpreted as meaning the last day of the preceding month.
.LP
The glibc version of \fIstruct tm\fP has additional fields
.PP
.in +4n
.EX
.sp
.RS
.nf
long tm_gmtoff; /* Seconds east of UTC */
const char *tm_zone; /* Timezone abbreviation */
.fi
.RE
.sp
.EE
.in
.PP
defined when
.B _BSD_SOURCE
was set before including

View File

@ -122,13 +122,13 @@ an initialization function to be called first.
All the functions work by generating a sequence of 48-bit integers,
.IR Xi ,
according to the linear congruential formula:
.sp
.nf
.RS
.PP
.in +4n
.EX
.B Xn+1 = (aXn + c) mod m, where n >= 0
.RE
.fi
.sp
.EE
.in
.PP
The parameter
.I m
= 2^48, hence 48-bit integer arithmetic is performed.
@ -139,14 +139,14 @@ is called,
and
.I c
are given by:
.sp
.nf
.RS
.PP
.in +4n
.EX
.B a = 0x5DEECE66D
.B c = 0xB
.RE
.fi
.sp
.EE
.in
.PP
The value returned by any of the functions
.BR drand48 (),
.BR erand48 (),

View File

@ -405,7 +405,7 @@ No such device or address (POSIX.1).
.TP
.B EOPNOTSUPP
Operation not supported on socket (POSIX.1).
.sp
.IP
.RB ( ENOTSUP
and
.B EOPNOTSUPP
@ -466,7 +466,7 @@ No such process (POSIX.1).
.TP
.B ESTALE
Stale file handle (POSIX.1).
.sp
.IP
This error can occur for NFS and for other filesystems.
.TP
.B ESTRPIPE
@ -475,7 +475,7 @@ Streams pipe error.
.B ETIME
Timer expired.
(POSIX.1 (XSI STREAMS option))
.sp
.IP
(POSIX.1 says "STREAM
.BR ioctl (2)
timeout")