From 817cd651c3a63686b7ce4083918c12f5ff4f72b4 Mon Sep 17 00:00:00 2001 From: Jeff Hill Date: Fri, 2 May 2003 17:43:07 +0000 Subject: [PATCH] optimization --- src/cas/generic/casAsyncPVAttachIOI.cpp | 16 ++++++---------- src/cas/generic/casAsyncPVExistIOI.cpp | 3 --- 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/src/cas/generic/casAsyncPVAttachIOI.cpp b/src/cas/generic/casAsyncPVAttachIOI.cpp index 360e48e83..d68ebcfa2 100644 --- a/src/cas/generic/casAsyncPVAttachIOI.cpp +++ b/src/cas/generic/casAsyncPVAttachIOI.cpp @@ -38,23 +38,19 @@ caStatus casAsyncPVAttachIOI::cbFuncAsyncIO ( { caStatus status; - switch ( this->msg.m_cmmd ) { - case CA_PROTO_CREATE_CHAN: + if ( this->msg.m_cmmd == CA_PROTO_CREATE_CHAN ) { status = this->client.createChanResponse ( guard, this->msg, this->retVal ); - if ( status == S_cas_sendBlocked ) { - return status; - } - break; - - default: + } + else { errPrintf ( S_cas_invalidAsynchIO, __FILE__, __LINE__, " - client request type = %u", this->msg.m_cmmd ); status = S_cas_invalidAsynchIO; - break; } - this->client.uninstallAsynchIO ( *this ); + if ( status != S_cas_sendBlocked ) { + this->client.uninstallAsynchIO ( *this ); + } return status; } diff --git a/src/cas/generic/casAsyncPVExistIOI.cpp b/src/cas/generic/casAsyncPVExistIOI.cpp index 566f680f0..271f96cfd 100644 --- a/src/cas/generic/casAsyncPVExistIOI.cpp +++ b/src/cas/generic/casAsyncPVExistIOI.cpp @@ -51,9 +51,6 @@ caStatus casAsyncPVExistIOI::cbFuncAsyncIO ( status = this->client.asyncSearchResponse ( guard, this->dgOutAddr, this->msg, this->retVal, this->protocolRevision, this->sequenceNumber ); - if ( status == S_cas_sendBlocked ) { - return status; - } } else { errPrintf ( S_cas_invalidAsynchIO, __FILE__, __LINE__,