[Bug nptl/17214] Expose a function to reset the PID cache

sstewartgallus00 at mylangara dot bc.ca sourceware-bugzilla@sourceware.org
Tue Aug 26 18:11:00 GMT 2014


https://sourceware.org/bugzilla/show_bug.cgi?id=17214

--- Comment #7 from Steven Stewart-Gallus <sstewartgallus00 at mylangara dot bc.ca> ---
Strange, Rich.

The source in pthread_join says:

    /* Wait for the child.  */
    lll_wait_tid (pd->tid);

However, I'm sure I wasn't mistaken when my code was randomly failing
at unshare(CLONE_NEWPID).

The idea that the pthread_join completed before the kernel recognized
the thread as dead seemed very logical to me but I may be wrong.
Alternatively, there could a tiny bug in the kernel or in GLibc as
this logic is probably infreguently tested.  I'll try to create a
reduced test for the problem.

In any case, unshare(CLONE_NEWPID); then fork is kind of fragile and
weird (for one, the spawned process after fork doesn't get immunity to
signals like an init should).

-- 
You are receiving this mail because:
You are on the CC list for the bug.



More information about the Glibc-bugs mailing list