Subject: [Boost-bugs] [Boost C++ Libraries] #5123: Interprocess: permissions are changed when opening a memory segment
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2011-01-26 12:19:03
#5123: Interprocess: permissions are changed when opening a memory segment
------------------------------+---------------------------------------------
Reporter: xavi@⦠| Owner: igaztanaga
Type: Bugs | Status: new
Milestone: To Be Determined | Component: interprocess
Version: Boost 1.45.0 | Severity: Problem
Keywords: |
------------------------------+---------------------------------------------
In linux, fchmod is used to set the permissions after successfully
shm_opening a segment.
This is good to circumvent the problems caused by umask, but there is an
error and fchmod is also run when opening (as opposed to creating) the
segment, which means that opening a segment always resets its permissions
to the defaults.
This can be easily fixed by changing, in shared_memory_object.hpp, the
line
if(m_handle >= 0)
right before the fchmod with:
if(m_handle >= 0 && type != detail::DoOpen)
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/5123> 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