From 0e4f45dac5df8e06d5cab31047d3188a11254967 Mon Sep 17 00:00:00 2001 From: Jeff Hill Date: Tue, 6 Jun 2006 23:09:25 +0000 Subject: [PATCH] fixed mantis 260 --- src/ca/cac.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/ca/cac.cpp b/src/ca/cac.cpp index 7d173421a..df85787a6 100644 --- a/src/ca/cac.cpp +++ b/src/ca/cac.cpp @@ -497,6 +497,12 @@ void cac::transferChanToVirtCircuit ( if ( ! sockAddrAreIdentical ( &addr, &chanAddr ) ) { char acc[64]; pChan->getPIIU(guard)->getHostName ( guard, acc, sizeof ( acc ) ); + // It is possible for the ioInitiate call below to + // call the callback directly if queue quota is exceeded. + // This callback takes the callback lock and therefore we + // must release the primary mutex here to avoid a lock + // hierarchy inversion. + epicsGuardRelease < epicsMutex > unguard ( guard ); msgForMultiplyDefinedPV * pMsg = new ( this->mdpvFreeList ) msgForMultiplyDefinedPV ( this->ipToAEngine, *this, pChan->pName ( guard ), acc );