diff options
author | Benoit Foucher <benoit@zeroc.com> | 2018-03-01 14:00:39 +0100 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2018-03-01 14:00:39 +0100 |
commit | 6a53b1575ed0f855108abc5184744c2529c151ae (patch) | |
tree | 6e9188775461599b5c83890e226da62e5f255a7f /cpp/src/Ice/ThreadPool.cpp | |
parent | Fixed JS test suite hang (ICE-8696) (diff) | |
download | ice-6a53b1575ed0f855108abc5184744c2529c151ae.tar.bz2 ice-6a53b1575ed0f855108abc5184744c2529c151ae.tar.xz ice-6a53b1575ed0f855108abc5184744c2529c151ae.zip |
Fixed UWP transport to cancel read/write operations on close (ICE-8686)
Diffstat (limited to 'cpp/src/Ice/ThreadPool.cpp')
-rw-r--r-- | cpp/src/Ice/ThreadPool.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/cpp/src/Ice/ThreadPool.cpp b/cpp/src/Ice/ThreadPool.cpp index e1d5165c31f..6d514a48891 100644 --- a/cpp/src/Ice/ThreadPool.cpp +++ b/cpp/src/Ice/ThreadPool.cpp @@ -507,7 +507,7 @@ IceInternal::ThreadPool::finish(const EventHandlerPtr& handler, bool closeNow) return closeNow; #else // If there are no pending asynchronous operations, we can call finish on the handler now. - if(!(handler->_pending & SocketOperationWaitForClose)) + if(!handler->_pending) { _workQueue->queue(new FinishedWorkItem(handler, false)); _selector.finish(handler.get()); @@ -983,7 +983,7 @@ IceInternal::ThreadPool::startMessage(ThreadPoolCurrent& current) if(!current._handler->finishAsync(current.operation)) // Returns false if the handler is finished. { current._handler->_pending = static_cast<SocketOperation>(current._handler->_pending & ~current.operation); - if(!(current._handler->_pending & SocketOperationWaitForClose) && current._handler->_finish) + if(!current._handler->_pending && current._handler->_finish) { Lock sync(*this); _workQueue->queue(new FinishedWorkItem(current._handler, false)); @@ -1010,7 +1010,7 @@ IceInternal::ThreadPool::startMessage(ThreadPoolCurrent& current) else if(!current._handler->startAsync(current.operation)) { current._handler->_pending = static_cast<SocketOperation>(current._handler->_pending & ~current.operation); - if(!(current._handler->_pending & SocketOperationWaitForClose) && current._handler->_finish) + if(!current._handler->_pending && current._handler->_finish) { Lock sync(*this); _workQueue->queue(new FinishedWorkItem(current._handler, false)); @@ -1034,7 +1034,7 @@ IceInternal::ThreadPool::startMessage(ThreadPoolCurrent& current) else { current._handler->_pending = static_cast<SocketOperation>(current._handler->_pending & ~current.operation); - if(!(current._handler->_pending & SocketOperationWaitForClose) && current._handler->_finish) + if(!current._handler->_pending && current._handler->_finish) { Lock sync(*this); _workQueue->queue(new FinishedWorkItem(current._handler, false)); @@ -1069,7 +1069,7 @@ IceInternal::ThreadPool::finishMessage(ThreadPoolCurrent& current) current._handler->_pending = static_cast<SocketOperation>(current._handler->_pending & ~current.operation); } - if(!(current._handler->_pending & SocketOperationWaitForClose) && current._handler->_finish) + if(!current._handler->_pending && current._handler->_finish) { // There are no more pending async operations, it's time to call finish. Lock sync(*this); |