diff options
Diffstat (limited to 'cpp/src')
-rw-r--r-- | cpp/src/IcePatch/Server.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/cpp/src/IcePatch/Server.cpp b/cpp/src/IcePatch/Server.cpp index a81636eceeb..3e6d7cb559c 100644 --- a/cpp/src/IcePatch/Server.cpp +++ b/cpp/src/IcePatch/Server.cpp @@ -199,9 +199,11 @@ IcePatch::IcePatchService::stop() { if(_thread) { - IceUtil::Monitor<IceUtil::Mutex>::Lock sync(_monitor); - _shutdown = true; - _monitor.notify(); + { + IceUtil::Monitor<IceUtil::Mutex>::Lock sync(_monitor); + _shutdown = true; + _monitor.notify(); + } _thread->getThreadControl().join(); _thread = 0; } |