Re: Bug with fcntl(n, F_SETOWN, getpid) with NPTL 0.34

Roland McGrath <[email protected]> Fri, 17 Oct 2003 16:44:53 -0700
Newsgroups gmane.comp.lib.phil
Message-ID <[email protected]>
> It is incorrect for a program to use the value of getpid() as the
> argument to F_SETOWN.  It should be using the value returned from the
> gettid() system call (tid (current->pid) != pid (current-tgid)).  (Yes
> the naming is very confusing).  Unfortunately this is not made easy
> (gettid() is not a libc function), and the man page is no longer
> correct when it says process id.

This is incorrect.  The kernel is what needs to be fixed.