summaryrefslogtreecommitdiff
path: root/cpp/src/Ice/ACM.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2017-06-15 09:13:51 +0200
committerBenoit Foucher <benoit@zeroc.com>2017-06-15 09:13:51 +0200
commit145cf69b7cdd21e96d44c5bc5690f23e2e9d12fe (patch)
tree52444d61f215b1c20c08b0dc6141a327aeebb4e5 /cpp/src/Ice/ACM.cpp
parentmore BT test fixes (diff)
downloadice-145cf69b7cdd21e96d44c5bc5690f23e2e9d12fe.tar.bz2
ice-145cf69b7cdd21e96d44c5bc5690f23e2e9d12fe.tar.xz
ice-145cf69b7cdd21e96d44c5bc5690f23e2e9d12fe.zip
Fixed ICE-8056 - communicator waitForShutdown hang
Diffstat (limited to 'cpp/src/Ice/ACM.cpp')
-rw-r--r--cpp/src/Ice/ACM.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/cpp/src/Ice/ACM.cpp b/cpp/src/Ice/ACM.cpp
index bb620d07430..2c5ac0da78d 100644
--- a/cpp/src/Ice/ACM.cpp
+++ b/cpp/src/Ice/ACM.cpp
@@ -91,6 +91,14 @@ IceInternal::FactoryACMMonitor::destroy()
Lock sync(*this);
if(!_instance)
{
+ //
+ // Ensure all the connections have been cleared, it's important to wait here
+ // to prevent the timer destruction in IceInternal::Instance::destroy.
+ //
+ while(!_connections.empty())
+ {
+ wait();
+ }
return;
}
@@ -205,7 +213,7 @@ IceInternal::FactoryACMMonitor::runTimerTask()
if(!_instance)
{
_connections.clear();
- notify();
+ notifyAll();
return;
}