no need to maintain count of circuits insttalled when they are installed on a

doubly linked list
This commit is contained in:
Jeff Hill
2004-06-17 23:30:32 +00:00
parent 61a4d8a0d3
commit 33ee0cba83
2 changed files with 2 additions and 8 deletions
+2 -7
View File
@@ -137,8 +137,7 @@ cac::cac (
initializingThreadsId ( epicsThreadGetIdSelf() ),
initializingThreadsPriority ( epicsThreadGetPrioritySelf() ),
maxRecvBytesTCP ( MAX_TCP ),
beaconAnomalyCount ( 0u ),
circuitsInstalled ( 0u )
beaconAnomalyCount ( 0u )
{
if ( ! osiSockAttach () ) {
throwWithLocation ( caErrorCode (ECA_INTERNAL) );
@@ -256,13 +255,12 @@ cac::~cac ()
//
{
epicsGuard < epicsMutex > guard ( this->mutex );
while ( this->circuitsInstalled ) {
while ( this->circuitList.count() > 0 ) {
epicsGuardRelease < epicsMutex > unguard ( guard );
this->iiuUninstall.wait ();
}
}
if ( this->pudpiiu ) {
delete this->pudpiiu;
}
@@ -530,7 +528,6 @@ bool cac::transferChanToVirtCircuit (
}
this->serverTable.add ( *pnewiiu );
this->circuitList.add ( *pnewiiu );
this->circuitsInstalled++;
pBHE->registerIIU ( guard, *pnewiiu );
piiu = pnewiiu.release ();
newIIU = true;
@@ -1172,8 +1169,6 @@ void cac::destroyIIU ( tcpiiu & iiu )
{
epicsGuard < epicsMutex > guard ( this->mutex );
this->freeListVirtualCircuit.release ( & iiu );
assert ( this->circuitsInstalled > 0u );
this->circuitsInstalled--;
}
// signal iiu uninstal event so that cac can properly shut down
-1
View File
@@ -283,7 +283,6 @@ private:
unsigned initializingThreadsPriority;
unsigned maxRecvBytesTCP;
unsigned beaconAnomalyCount;
unsigned circuitsInstalled;
void run ();
void recycleReadNotifyIO (