cvs commit: src/lib/libc/gen pthread_fake.c src/lib/libc_r/uthread pthread_private.h uthread_atfork.c uthread_fork.c uthread_init.c

Matthew Dillon dillon at
Tue May 27 12:05:45 PDT 2008

:Joerg Sonnenberger wrote:
:> On Mon, May 26, 2008 at 12:53:56AM +0300, Hasso Tepper wrote:
:> > While I tested this pthread_atfork() implementation, I discovered one
:> > problem though. One of pthread_atfork() tests included in Open POSIX
:> > Test Suite [1] fails with it while it works with libthread_xu.
:> Can you describe in short what it is doing?
:=46rom the test source:
:* This sample test aims to check the following assertion:
:* The function does not return EINTR
:* The steps are:
:* -> kill a thread which calls pthread_atfork
:* -> check that EINTR is never returned
:With libthread_xu the test outputs:
:$ ./3-3.test
:[21:30:40]Test executed successfully.
:[21:30:40]  58840 operations.
:[21:30:40]  98757 signals were sent meanwhile.
:With libc_r it remains in infinite loop. You can read the source of the=20
:test in=20
:Hasso Tepper

    Ah, it took a few minutes but I think the reason it isn't working
    is simply because libc_r does not use real threads.  Because of
    this the other scheduled threads cannot run at all and thus the signal
    is never send, and the while () loops just keeps going off into infinity.

					Matthew Dillon 
					<dillon at>

More information about the Commits mailing list