2011-07-31 Joel Sherrill <joel.sherrilL@OARcorp.com>

PR 1867/cpukit
	* Makefile.am, configure.ac, psx12/task.c, psxkey03/init.c,
	psxrwlock01/test.c: Correct implementation of pthread_exit() and
	pthread_join() to support the case where a thread is joinable but
	calls pthread_exit() before a thread has attempted to join.
This commit is contained in:
Joel Sherrill
2011-07-31 16:16:17 +00:00
parent 25715ecc42
commit 76e9a52f29
6 changed files with 31 additions and 1 deletions

View File

@@ -30,6 +30,11 @@ void *Task_1(
void *argument
)
{
/*
* Detach ourselves so we don't wait for a join that won't happen.
*/
pthread_detach( pthread_self() );
puts( "Task_1: exitting" );
pthread_exit( NULL );