Re: [Boost-bugs] [Boost C++ Libraries] #7156: interprocess buffer streams leak memory on construction

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #7156: interprocess buffer streams leak memory on construction
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-09-03 21:58:35


#7156: interprocess buffer streams leak memory on construction
------------------------------------------------+--------------------------
  Reporter: Jonathan Jones <jonathan.jones@…> | Owner: igaztanaga
      Type: Bugs | Status: new
 Milestone: To Be Determined | Component: interprocess
   Version: Boost 1.44.0 | Severity: Problem
Resolution: | Keywords:
------------------------------------------------+--------------------------

Comment (by igaztanaga):

 This is a known problem of the MSVC STL implementation. However,
 basic_ios::init call should be called only once, as the standard does not
 give any guarantee to allow calling it twice (MSVC STL leaks in this
 case). As pointed in http://accu.org/index.php/journals/264 we need to
 take of a potentially throwing custom streambuf so that basic_ios is not
 destroyed without being initialized. This is not a problem for
 bufferstream (has nothrow constructors) but it could affect vectorstream.
 In this second case a null streambuf will be passed to initialize
 basic_[i/o]stream, which will call basic_ios::init. After that, the
 streambuf will be replaced with vectorstream.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/7156#comment:3>
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:14 UTC