fcntl.2: Note that glibc 2.11 papers over the kernel F_GETOWN bug

Since version 2.11, glibc works around the kernel limitation for
process groups IDs < 4096 by implementing F_GETOWN via F_GETOWN_EX.

Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Michael Kerrisk 2010-06-16 23:46:02 +02:00
parent a9f50aa383
commit 23a05d28b6
1 changed files with 8 additions and 4 deletions

View File

@ -56,7 +56,7 @@
.\" Note obsolete F_SETOWN behavior with threads.
.\" Document F_SETOWN_EX and F_GETOWN_EX
.\"
.TH FCNTL 2 2009-10-17 "Linux" "Linux Programmer's Manual"
.TH FCNTL 2 2010-06-17 "Linux" "Linux Programmer's Manual"
.SH NAME
fcntl \- manipulate file descriptor
.SH SYNOPSIS
@ -1159,14 +1159,18 @@ will be \-1, and
.I errno
will contain the (positive) process group ID.
The Linux-specific
.BR F_SETOWN_EX
and
.BR F_GETOWN_EX
operations avoid this problem.
operation avoids this problem.
.\" mtk, Dec 04: some limited testing on alpha and ia64 seems to
.\" indicate that ANY negative PGID value will cause F_GETOWN
.\" to misinterpret the return as an error. Some other architectures
.\" seem to have the same range check as i386.
Since glibc version 2.11, glibc makes the kernel
.B F_GETOWN
problem invisible by implementing
.B F_GETOWN
using
.BR F_GETOWN_EX .
In Linux 2.4 and earlier, there is bug that can occur
when an unprivileged process uses