From ac8dc4facdb74eb6d2cf2edecd9d31567893cf29 Mon Sep 17 00:00:00 2001 From: Jeff Hill Date: Fri, 30 Jul 2004 23:34:24 +0000 Subject: [PATCH] fixed locking associated with the cleanup flag (this is not a known problem, the problem was identified instead during code inspection) --- src/libCom/misc/ipAddrToAsciiAsynchronous.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp b/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp index 68b5dab82..ecdef00ea 100644 --- a/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp +++ b/src/libCom/misc/ipAddrToAsciiAsynchronous.cpp @@ -234,9 +234,12 @@ ipAddrToAsciiTransaction & ipAddrToAsciiEnginePrivate::createTransaction () void ipAddrToAsciiEnginePrivate::run () { + epicsGuard < epicsMutex > guard ( this->mutex ); while ( ! this->exitFlag ) { - this->laborEvent.wait (); - epicsGuard < epicsMutex > guard ( this->mutex ); + { + epicsGuardRelease < epicsMutex > unguard ( guard ); + this->laborEvent.wait (); + } while ( true ) { ipAddrToAsciiTransactionPrivate * pItem = this->labor.get (); if ( ! pItem ) {