Re: [Boost-bugs] [Boost C++ Libraries] #5021: io_service destructor hangs on Mac OS X

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #5021: io_service destructor hangs on Mac OS X
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2011-01-22 10:55:57


#5021: io_service destructor hangs on Mac OS X
------------------------------------------------+---------------------------
  Reporter: Remko Tronçon <remko@…> | Owner: chris_kohlhoff
      Type: Bugs | Status: new
 Milestone: To Be Determined | Component: asio
   Version: Boost 1.45.0 | Severity: Problem
Resolution: | Keywords:
------------------------------------------------+---------------------------

Comment (by chris_kohlhoff):

 Hmmm, if it's kqueue related, perhaps the interrupter's descriptor needs
 to be explicitly removed from the kqueue before closing:

 {{{

 --- kqueue_reactor.ipp 24 Oct 2010 04:03:09 -0000 1.1.2.7
 +++ kqueue_reactor.ipp 22 Jan 2011 10:52:47 -0000
 @@ -54,6 +54,11 @@

  kqueue_reactor::~kqueue_reactor()
  {
 + struct kevent event;
 + BOOST_ASIO_KQUEUE_EV_SET(&event, interrupter_.read_descriptor(),
 + EVFILT_READ, EV_DELETE, 0, 0, &interrupter_);
 + ::kevent(kqueue_fd_, &event, 1, 0, 0, 0);
 +
    close(kqueue_fd_);
  }
 }}}

 Just a stab in the dark really, but probably worth trying.

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