dont allow local PVs to connect unless the client ctx allows preemptive callback

This commit is contained in:
Jeff Hill
2002-01-09 00:57:23 +00:00
parent 3a126559a7
commit e343acdd57
2 changed files with 9 additions and 4 deletions

View File

@@ -101,15 +101,14 @@ extern "C" void putNotifyCompletion ( putNotify *ppn )
else {
errlogPrintf ( "put notify completion with nill pNotify?\n" );
}
// no need to lock here because only one put notify at a timeis lalowed to run
// no need to lock here because only one put notify at a time is lalowed to run
memset ( &pBlocker->pn, '\0', sizeof ( pBlocker->pn ) );
pBlocker->pNotify = 0;
pBlocker->block.signal ();
}
void dbPutNotifyBlocker::initiatePutNotify ( epicsMutex &mutex, cacWriteNotify &notify,
struct dbAddr &addr, unsigned type, unsigned long count,
const void *pValue )
void dbPutNotifyBlocker::initiatePutNotify ( epicsMutex &mutex, cacWriteNotify & notify,
struct dbAddr & addr, unsigned type, unsigned long count, const void * pValue )
{
int status;

View File

@@ -90,6 +90,12 @@ cacChannel *dbServiceIO::createChannel (
if ( status ) {
return 0;
}
else if ( ! ca_preemtive_callback_is_enabled () ) {
errlogPrintf (
"dbServiceIO: preemptive callback required for
\n memory interfacing of CA channels to the DB\n" );
return 0;
}
else {
return new dbChannelIO ( notify, addr, *this );
}