Re: [Boost-bugs] [Boost C++ Libraries] #4522: allocation problem after grow

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #4522: allocation problem after grow
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2010-08-08 11:12:26


#4522: allocation problem after grow
-------------------------------+--------------------------------------------
  Reporter: razzik@… | Owner: igaztanaga
      Type: Bugs | Status: closed
 Milestone: Boost 1.44.0 | Component: interprocess
   Version: Boost 1.43.0 | Severity: Showstopper
Resolution: invalid | Keywords: interprocess shared_memory ipc grow allocation
-------------------------------+--------------------------------------------

Comment (by Raz <razzik@…>):

 '''Thanks igaztanaga!!'''

 You are right, in general the growing should be when the SM is unmapped.

 Basically, I need shared memory with Fix memory size.
 But, I don't know the memory size used by Shared Memory mechanism.
 So, I use grow after using ''get_free_memory()'' function.

 '''How can I set in the constructor of the managed_shared_memory the
 required memory without knowing the SM mechanism size?'''

 Thanks again for your assistance,[[BR]]Raz

 P.S.
 General question:
 If the SM based on file I can't call ''shrink_to_fit()'' when the SM is
 mapped,
 But what about grow?

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/4522#comment:2>
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:04 UTC