supress channel destroy exception in "old" API layer

This commit is contained in:
Jeff Hill
2001-08-16 01:19:52 +00:00
parent 9bbb9c1314
commit 93e745ef83
3 changed files with 25 additions and 19 deletions

View File

@@ -49,14 +49,16 @@ void getCallback::exception (
int status, const char * /* pContext */,
unsigned type, arrayElementCount count )
{
struct event_handler_args args;
args.usr = this->pPrivate;
args.chid = &this->chan;
args.type = type;
args.count = count;
args.status = status;
args.dbr = 0;
( *this->pFunc ) ( args );
if ( status != ECA_CHANDESTROY ) {
struct event_handler_args args;
args.usr = this->pPrivate;
args.chid = &this->chan;
args.type = type;
args.count = count;
args.status = status;
args.dbr = 0;
( *this->pFunc ) ( args );
}
delete this;
}

View File

@@ -64,8 +64,11 @@ void getCopy::completion ( unsigned typeIn,
void getCopy::exception (
int status, const char *pContext, unsigned /* typeIn */, arrayElementCount /* countIn */ )
{
this->cacCtx.exception ( status, pContext,
__FILE__, __LINE__, this->chan, this->type, this->count, CA_OP_GET );
if ( status != ECA_CHANDESTROY ) {
this->cacCtx.exception ( status, pContext,
__FILE__, __LINE__, this->chan, this->type,
this->count, CA_OP_GET );
}
delete this;
}

View File

@@ -49,15 +49,16 @@ void putCallback::exception (
int status, const char * /* pContext */,
unsigned type, arrayElementCount count )
{
struct event_handler_args args;
args.usr = this->pPrivate;
args.chid = & this->chan;
args.type = type;
args.count = count;
args.status = status;
args.dbr = 0;
( *this->pFunc ) (args);
if ( status != ECA_CHANDESTROY ) {
struct event_handler_args args;
args.usr = this->pPrivate;
args.chid = & this->chan;
args.type = type;
args.count = count;
args.status = status;
args.dbr = 0;
( *this->pFunc ) (args);
}
delete this;
}