added preemptive callback control

reinstalled flow control
This commit is contained in:
Jeff Hill
2000-06-22 23:59:51 +00:00
parent a0c9a0ea91
commit 47729fed41
14 changed files with 480 additions and 354 deletions

View File

@@ -89,6 +89,7 @@ int CASG::block ( double timeout )
if ( p ) {
return ECA_EVDISALLOW;
}
threadPrivateSet (cacRecursionLock, &cacRecursionLock);
cur_time = osiTime::getCurrent ();
@@ -98,6 +99,8 @@ int CASG::block ( double timeout )
beg_time = cur_time;
delay = 0.0;
this->client.enableCallbackPreemption ();
status = ECA_NORMAL;
while ( 1 ) {
this->mutex.lock ();
@@ -135,9 +138,6 @@ int CASG::block ( double timeout )
break;
}
/*
* wait for asynch notification
*/
this->sem.wait ( remaining );
/*
@@ -148,6 +148,8 @@ int CASG::block ( double timeout )
delay = cur_time - beg_time;
}
this->client.disableCallbackPreemption ();
threadPrivateSet (cacRecursionLock, NULL);
return status;