Re: [Boost-bugs] [Boost C++ Libraries] #11275: Deadlock when destroying continuation future

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #11275: Deadlock when destroying continuation future
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-09-05 14:54:23


#11275: Deadlock when destroying continuation future
-------------------------------------+-------------------------------------
  Reporter: Konrad Zemek | Owner: viboes
  <konrad.zemek@…> | Status: assigned
      Type: Bugs | Component: thread
 Milestone: To Be Determined | Severity: Problem
   Version: Boost 1.58.0 | Keywords: continuation deadlock
Resolution: | destructor
-------------------------------------+-------------------------------------

Comment (by viboes):

 The code in develop (or >=boost.1.58) contains now

 {{{
 #if defined BOOST_THREAD_PROVIDES_FUTURE_CONTINUATION
             void do_continuation(boost::unique_lock<boost::mutex>& lock)
             {
                 if (! continuations.empty()) {
                   continuations_type the_continuations = continuations;
                   continuations.clear();
                   relocker rlk(lock);
                   for (continuations_type::iterator it =
 the_continuations.begin(); it != the_continuations.end(); ++it) {
                     (*it)->launch_continuation();
                   }
                 }
             }
 #else
             void do_continuation(boost::unique_lock<boost::mutex>&)
             {
             }
 #endif
 }}}


 Please could you give a try?

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/11275#comment:6>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:19 UTC