bool GraphBase::DataPort::BoolValue() const {
bool RetVal = false ;
- long val ;
pthread_mutex_t * aMutexWait = (pthread_mutex_t *) &_MutexWait ;
// cdebug << pthread_self() << " BoolValue() --> pthread_mutex_lock " << aMutexWait << endl ;
if ( pthread_mutex_lock( aMutexWait ) ) {
// cdebug << pthread_self() << " BoolValue() --> pthread_mutex_locked " << aMutexWait
// << endl ;
if ( (*_Value)->type()->kind() == CORBA::tk_long ) {
+ long val ;
+ **_Value >>= val ;
+ if ( val ) {
+ RetVal = true ;
+ }
+ }
+ else if ( (*_Value)->type()->kind() == CORBA::tk_boolean ) {
+ bool val ;
**_Value >>= val ;
if ( val ) {
RetVal = true ;
perror( "unlock DataValue" ) ;
exit( 0 ) ;
}
-// cdebug << pthread_self() << " BoolValue() --> pthread_mutex_unlocked " << aMutexWait
-// << endl ;
+ cdebug << pthread_self() << " " << NodeName() << "( " << PortName() << " ) BoolValue " << RetVal << endl ;
return RetVal ;
}