[277] in Pthreads mailing list archive
Re: pthreads and fork()
daemon@ATHENA.MIT.EDU (Samuel Tardieu)
Mon Feb 26 09:11:20 1996
To: Christopher Provenzano <proven@MIT.EDU>
Cc: Samuel Tardieu <sam@inf.enst.fr>, pthreads@MIT.EDU
Date: 26 Feb 1996 14:19:51 +0100
In-Reply-To: Christopher Provenzano's message of Tue, 20 Feb 1996 15:26:38 EST
Reply-To: Samuel Tardieu <sam@inf.enst.fr>
From: Samuel Tardieu <sam@inf.enst.fr>
>>>>> "Christopher" == Christopher Provenzano <proven@MIT.EDU> writes:
Christopher> The sleep() call is deadlocking pthreads because pthreads
Christopher> assumes that you are going to call exec() fairly soon
Christopher> after calling fork() (This is also what POSIX assumes)
Christopher> and has turned off all scheduling operations.
Christopher> Work is under way to make the behavior of fork() more
Christopher> reasonable by tring to eliminate the scheduling deadlock
Christopher> problems but it is adviseable to still call exec()
Christopher> shortly after calling fork() becuase the fork() call will
Christopher> still only create a child process with the current thread
Christopher> running as per the POSIX standard.
Unfortunately, I don't want to exec anything ; the fork() was here to
release the parent process-id which terminates just after the fork()
occurs. I want to detach the current process...
Sam
--
"La cervelle des petits enfants, ca doit avoir comme un petit gout de noisette"
Charles Baudelaire