This replaces the previous '.so' man page link file for
rt_sigqueueinfo.2, which linked to ths sigqueue() man page.
Reported-by: Stephan Mueller <stephan.mueller@atsec.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
We've recently discovered that GDB will fail to attach to any
process that sets itself non-dumpable. Tested on kernel 2.6.32,
with:
int main(int argc, char *argv[])
{
if (prctl(PR_SET_DUMPABLE, 0, 0, 0) != 0) {
perror("prctl");
}
printf("Run gdb %s %d\n", argv[0], getpid());
sleep(20);
abort();
}
./a.out
Run gdb ./a.out 30476
gdb -q ./a.out 30476
Reading symbols from /tmp/a.out...done.
Attaching to program: /tmp/a.out, process 30476
ptrace: Operation not permitted.
/tmp/30476: No such file or directory.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
The current version of the page says (under ERRORS):
> EBUSY (not on Linux)
> The file pathname cannot be unlinked because it is being
> used by the system or another process and the
> implementation considers this an error.
But if you look in the kernel source file fs/namei.c
at routine may_delete() you'll see two occasions where
an EBUSY is generated. So the above "not on Linux" is wrong.
I suggest that this '(not on Linux)' be removed. It may
also improve the page if the commentary is reworded to give a
better description of the two situations. Something along
the lines of:
> The file pathname cannot be unlinked because it is being used
> by the system, e.g. if some (relative) rootdir is mounted upon it,
> or because the NFS client software created it to represent an
> active but otherwise nameless inode ("NFS silly renamed").
Just FYI: the NFS silly rename (you'll find this term mentioned
in the kernel source code) is described at:
http://nfs.sourceforge.net/#section_d
under section D2. The reason I found this manpage bug is because
I stumbled upon one of these silly renamed files, and an strace
of the rm-command revealed the EBUSY return errno.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
See http://bugs.debian.org/cgi-bin/bugreport.cgi?641513
timerfd_settime(2) states that "The old_value argument returns a
structure containing the setting of the timer that was current at
the time of the call"; however, it does not mention that the
caller can pass NULL to ignore that value. Only the example
shows that the caller can pass NULL.
Reported-by: Josh Triplett <josh@joshtriplett.org>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
Linux kernel commit cc56f7de7f00d188c7c4da1e9861581853b9e92f
meant sendfile(2) can work with any output file.
Therefore the 'out_fd' of sendfile(2) can refer to any file
(since Linux 2.6.33).
Signed-off-by: Akira Fujita <a-fujita@rs.jp.nec.com>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
The description of the example program says that it makes the
third page "read-only". Thus use PROT_READ instead of PROT_NONE.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>