Fix some formatting typos
* the period should be in Roman font
* .RP does not exist, it should be .RB
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
get_thread_area.2 is a system call.
Other manpages seems to differentiate functions (i.e. (g)lib(c) functions)
and system calls. This make it more consistent.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
See http://bugzilla.kernel.org/show_bug.cgi?id=13569
As noted by Andrey:
The purpose of the assert macro, defined in <assert.h>,
is to provide a tool to check for programming mistakes
or program logic errors. However, the assert macro must
never be used to perform checks for run time errors,
since, with the NDEBUG macro defined, expressions within
the assert macro invocations are not evaluated/checked
for, resulting in behavior that was not originally intended.
...
The pages affected in the core package are
execve(2)
pipe(2)
tee(2)
fmemopen(3)
mq_notify(3)
qsort(3)
Reported-by: Andrey Vihrov <vihrov@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Starting with Linux 2.6.30, the MS_RELATIME behavior became
the default, and MS_STRICTATIME is required to obtain the
traditional semantics.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Some bit rot had crept in regarding the discussion of the
number of arguments in older versions of this syscall.
Simplify the text to just say that Linux 2.4 and earlier
didn't have ptid, tls, and ctid arguments.
See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=533868
Reported-by: Shachar Shemesh <shachar@debian.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
As reported by Motohiro:
"man poll" describe this error code.
>ERRORS
> EBADF An invalid file descriptor was given in one of the sets.
but current kernel implementation ignore invalid file descriptor,
not return EBADF.
...
In the other hand, SUSv3 talk about
> POLLNVAL
> The specified fd value is invalid. This flag is only valid in the
> revents member; it shall ignored in the events member.
and
> If the value of fd is less than 0, events shall be ignored, and
> ireevents shall be set to 0 in that entry on return from poll().
but, no desribe EBADF.
(see http://www.opengroup.org/onlinepubs/009695399/functions/poll.html)
So, I think the implementation is correct.
Why don't we remove EBADF description?
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Reported-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
It was noted on lkml that the fork behaviour is documented
for the POSIX AIO calls, but not for the Linux native calls.
Here is a patch which adds a small blurb that folks will
hopefully find useful.
Upon fork(), the child process does not inherit the
io_context_t data structures returned by io_setup,
and thus cannot submit further asynchronous I/O or
reap event completions for said contexts.
Signed-off-by: Jeff Moyer <jmoyer@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
These operations use the 'data' argument as a signal number,
like PTRACE_CONT.
Reported-by: Mike Frysinger <vapier@gentoo.org>
Reported-by: Roland McGrath <roland@redhat.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
The 'msghdr' structure includes a field of type 'iovec',
so show the definition of that structure in this page.
Reported-by: Johannes Stezenbach <js@sig21.net>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
No actual change to formatted output, but this makes the
page sources more consistent for the purpose of grepping, etc.
Reported-by: Sam Varshavchik <mrsam@courier-mta.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
For a non-blocking socket, POSIX.1-2001/2008 allow either
EAGAIN or EWOULDBLOCK to be returned in cases where a call
would have blocked. Although these constants are defined
with the same value on most Linux architectures (PA-RISC
is the exception), POSIX.1 does not require them to have
the same value. Therefore, a portable application using
the sockets API should test for both errors when checking
this case.
(NB POSIX.1 only mentions EWOULDBLOCK in the context of
the sockets interfaces.)
Change made after a note cross-posted on linux-arch@vger,
http://thread.gmane.org/gmane.linux.debian.ports.hppa/5615
and a suggestion for write(2) from Carlos O'Donell
Reported-by: Carlos O'Donell <carlos@systemhalted.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
In the kernel, the error on encountering a mandatory lock is
EAGAIN. Although EAGAIN and EWOULDBLOCK are the same on
most Linux architectures, on some they are not, so don't
mention EWOULDBLOCK as it is misleading. (Mea culpa.)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Target file cannot be opened in append (O_APPEND) mode
In kernels prior to v2.6.27 splice() to a file in append mode is broken,
and since that version it is disallowed. It is possible this behaviour
may change in the future; see the kernel commit message
(efc968d450e013049a662d22727cf132618dcb2f) for more information.
Signed-off-by: Mark Hills <mark@pogo.org.uk>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
In SEE ALSO, when a few man pages are referenced, those are divided by commas.
Every reference is on a separate line, and all lines but the last one should
end with comma. I spotted one place where there is no comma in between
references, and mocked up an awk script to find similar places:
for f in man*/*; do awk '/^.SH ["]SEE ALSO["]/ {sa=1; print "== " FILENAME " =="; print; next } /^\.(PP|SH)/ {sa=0; no=0; next} /^\.BR/ { if (sa==1) { print; if (no == 1) print "Missing comma in " FILENAME " +" FNR-1; no=0 } } /^\.BR .*)$/ { if (sa==1) no=1; next } /\.\\"/ {next} /.*/ { if (sa==1) { print; next }}' $f; done | fgrep 'Missing comma'
This patch fixes all the places found by the above script.
Also, there is an extra dot at the end of uri.7 "SEE ALSO" section.
Removed as per man-pages(7) recommendation.
Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
The POSIX timers API is implemented (mostly) within the kernel,
so thse interfaces are system calls. Although there are as yet
no man pages, when they are added they should be in Section 2,
not 3. Therefore fix those pages that currently refer to these
interfaces as being in Section 3.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
While writing a little program using capset
I found the capset manpage quite light on crucial
details and I had to resort to RTFS.
This patch improves the points I found unclear
and also moves one misplaced paragraph around.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Sebastien pointed out that the first example program
wrongly thinks it can count signals.
Also, some further rewrites by mtk.
Reported-by: Sebastian Kienzl <seb@riot.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Since d_type will always just return DT_UNKNOWN before
kernel 2.6.4, we don't need to use a conditional for
determining whether we use this flag.
Reported-by: Bastien ROUCARIES <roucaries.bastien@gmail.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This error is encountered when the limit imposed by
/proc/sys/fs/epoll/max_user_instances is encountered.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This error results when the limit imposed by
/proc/sys/fs/epoll/max_user_watches is encountered.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Introduce notion of epoll instance as distinct from epoll file descriptor.
Plus other wording clean-ups.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Reword so that the notion of an epoll instance is made clear,
and made distinct from the notion of an epoll file descriptor.
Some other minor rewordings also.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
The page text described the semantics of the initial
implementation of signalfd(). These were changed early on,
but the man page wasn't updated.
Reported-by: Vegard Nossum <vegard.nossum@gmail.com>
Reviewed-by: Davide Libenzi <davidel@xmailserver.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
The interfaces documented in this page are purely glibc.
Reported-by: Colin Watson <cjwatson@ubuntu.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
When a 32-bit app opens a file whose size is too big to be
represented in 31-bits, POSIX.1 specifies the error EOVERFLOW.
Linux used to give EFBIG for this case, but 2.6.24 fixed this.
Also, add some text to describe the error scenario in
more detail.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Some errors were listed under a separate "may" heading.
There's probably no real need to do this; integrate
those errors into the main list.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Most other sockets pages are using the names 'addr'
and 'addrlen'; make these pages do the same.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
If the recvfrom() returned address is truncated, the 'fromlen'
argument indicates the actual size of the address, rather than
a count of the number of bytes in the truncated buffer.
Also clarify that the 'from' argument can be NULL, in which
case 'fromlen' should is unused, and should also be NULL.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
If the returned address is truncated, the 'addrlen' argument
indicates the actual size of the address, rather than a count
of the number of bytes in the truncated buffer.
Also clarify that if 'addr' argument is NULL, then 'addrlen'
should is unused, and should also be NULL.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Many sockets man pages use the name 'sockfd' already.
For consistency, changes the others to do so as well.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Mel Gorman reported that in Linux 2.6.27, 'addr' is rounded
down to a page boundary.
Before kernel 2.6.26, if 'addr' was taken as a hint, it was
rounded up to the next page boundary. Since Linux 2.6.24,
it is rounded down. Therefore, loosen the description of
this point to say that the address is rounded to "a nearby
page boundary".
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Reported-by: Mel Gorman <mel@csn.ul.ie>
Internet datagram (since Linux 2.4.27/2.6.8),
and netlink (since Linux 2.6.22) sockets support
the MSG_TRUNC flag for recv(2).
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Expand description of setdomainname() and getdomainname().
Note that getdomainname() is implemented as a library function
in glibc.
Note limits on size of domain name.
Reorganize ERRORS list.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Write a paragraph describing sethostname().
Clarify differences between glibc's gethostbyname() and
the kernel gethostbyname() system calls.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
If CLONE_NEWUTS is specified, the IDs are initialized
by duplicating from calling process.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Reviewed-by: Serge E. Hallyn <serge@hallyn.com>
Many pages still mention use of the obsolete sysctl(2) system
call, or used the term "sysctls"; rewrite these mentions to
instead be in terms of /proc interfaces.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This was already stated under NOTES, but make it even more
prominent by adding a sentence at the start of the DESCRIPTION.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
When the last process in an IPC namespace is destroyed, the
IPC objects in that namespace are automatically destroyed.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Reported-by: Cedric Le Goater <clg@fr.ibm.com>
This is more consistent with the term "mounts namespace"
used in the 2008 ACM SIGOPS paper, "Virtual servers
and and checkpoint/restart in mainstream Linux".
(I avoided the "s", because using the plural strikes me
as klunky English, and anyway we don't talk about
the "PIDs namespace" or the "networks namespace", etc..)
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>