Changed to account for ownership only being tracked when a priority

blocking protocol is used.
This commit is contained in:
Joel Sherrill
1998-12-03 23:01:22 +00:00
parent 6afa6e3996
commit 41616f6513
2 changed files with 16 additions and 0 deletions

View File

@@ -269,6 +269,14 @@ void *POSIX_Init(
status = pthread_mutexattr_init( &attr );
assert( !status );
/*
* Set the protocol to priority ceiling so the owner check happens
* and the EPERM test (later) will work.
*/
status = pthread_mutexattr_setprotocol( &attr, PTHREAD_PRIO_INHERIT );
assert( !status );
puts( "Init: pthread_mutex_init - SUCCESSFUL" );
status = pthread_mutex_init( &Mutex_id, &attr );
if ( status )