Skip to content

Commit

Permalink
Fixes #234 ("Conversion warning in ipcdetail::block_header")
Browse files Browse the repository at this point in the history
  • Loading branch information
igaztanaga committed Sep 29, 2024
1 parent 6c8f351 commit 5e6e09e
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions include/boost/interprocess/detail/segment_manager_helper.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -264,16 +264,14 @@ struct block_header
public:
typedef unsigned short name_len_t;

BOOST_STATIC_CONSTEXPR size_type value_mask = ~size_type(0) >> 2u;

block_header(size_type val_bytes
,size_type
,unsigned char al_type
,std::size_t
,std::size_t
)
: m_alloc_type(al_type & 3u)
, m_value_bytes(val_bytes& (value_mask))
, m_value_bytes(val_bytes & (~size_type(0) >> 2u))
{};

template<std::size_t TypeAlignment>
Expand Down

0 comments on commit 5e6e09e

Please sign in to comment.