Re: [Boost-bugs] [Boost C++ Libraries] #11457: boost::recursive_mutex leaks event handles when lock contention occurs.

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #11457: boost::recursive_mutex leaks event handles when lock contention occurs.
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-11-10 17:15:35


#11457: boost::recursive_mutex leaks event handles when lock contention occurs.
-------------------------------+-----------------------------------------
  Reporter: al.mendall@… | Owner: viboes
      Type: Bugs | Status: assigned
 Milestone: To Be Determined | Component: thread
   Version: Boost 1.46.0 | Severity: Problem
Resolution: | Keywords: handle leak recursive_mutex
-------------------------------+-----------------------------------------

Comment (by anonymous):

 Yes, the handle leak occurs in Windows. I have not experienced it in
 Linux. Here is a simple example class.

 class UserInfo
 {
     boost::recursive_mutex m_Lock;
     bool IsEntitled (const unsigned int uBit);
 }

 bool CUserInfo::IsEntitled (const unsigned int uBit)
 {
     bool bRet = false;
     boost::recursive_mutex::scoped_lock lock (m_Lock);
     //do something...anything that takes a few nanoseconds.
     return bRet;
 }

 You can see the leak by creating a simple windows app that launches
 multiple threads and puts them each in a loop calling IsEntitled. It will
 leak event handles for each (or maybe just some?) lock contention events.
 So the more threads you launch, the more handle leaks you will see.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/11457#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