Modify

Opened 6 years ago

Closed 6 years ago

#5123 closed Bugs (fixed)

Interprocess: permissions are changed when opening a memory segment

Reported by: xavi@… Owned by: igaztanaga
Milestone: To Be Determined Component: interprocess
Version: Boost 1.45.0 Severity: Problem
Keywords: Cc:

Description

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?)

Attachments (0)

Change History (1)

comment:1 Changed 6 years ago by igaztanaga

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in Boost 1.47

Add Comment

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain igaztanaga.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.