Re: [Boost-bugs] [Boost C++ Libraries] #8600: wait_for_any hangs, if called with multiple copies of shared_future referencing same task

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #8600: wait_for_any hangs, if called with multiple copies of shared_future referencing same task
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-05-27 06:50:51


#8600: wait_for_any hangs, if called with multiple copies of shared_future
referencing same task
---------------------------------------------------+------------------------
  Reporter: Martin Apel <martin.apel@…> | Owner: viboes
      Type: Bugs | Status: assigned
 Milestone: To Be Determined | Component: thread
   Version: Boost 1.53.0 | Severity: Problem
Resolution: | Keywords:
---------------------------------------------------+------------------------

Comment (by Martin Apel <martin.apel@…>):

 Interesting. I see that it's strange to explicitly pass two identical
 objects in there, but I would still expect it to wait correctly and not to
 silently hang infinitely. When called with iterators, this becomes more
 natural, because it's nothing special if a list contains the same item
 twice.

 I would be perfectly happy to avoid this situation, if there only was a
 possibility to detect his. I have now found a workaround for my
 application, where I pass additional data and filter out futures based on
 this additional data. The best approach for me would be, if there was an
 operator== for shared_future objects, so I can compare, if they point to
 the same object or not. This would not incur any overhead and still make
 my use case possible.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/8600#comment:5>
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:13 UTC