==12425== Memcheck, a memory error detector ==12425== Copyright (C) 2002-2013, and GNU GPL'd, by Julian Seward et al. ==12425== Using Valgrind-3.10.0.SVN and LibVEX; rerun with -h for copyright info ==12425== Command: ./offset_ptr_test ==12425== Parent PID: 25536 ==12425== ==12425== Invalid read of size 4 ==12425== at 0x403C1A: boost::interprocess::offset_ptr >, long, int, 0ul>::get() const (offset_ptr.hpp:346) ==12425== by 0x4038D5: boost::intrusive::pointer_plus_bits >, long, int, 0ul>, 1ul>::set_pointer(boost::interprocess::offset_ptr >, long, int, 0ul>&, boost::interprocess::offset_ptr >, long, int, 0ul> const&) (offset_ptr.hpp:702) ==12425== by 0x40327C: boost::intrusive::compact_rbtree_node_traits_impl >::set_parent(boost::interprocess::offset_ptr >, long, int, 0ul> const&, boost::interprocess::offset_ptr >, long, int, 0ul> const&) (rbtree_node.hpp:138) ==12425== by 0x403215: boost::intrusive::bstree_algorithms, true> >::init_header(boost::interprocess::offset_ptr >, long, int, 0ul> const&) (bstree_algorithms.hpp:619) ==12425== by 0x404ECB: boost::intrusive::rbtree_algorithms, true> >::init_header(boost::interprocess::offset_ptr >, long, int, 0ul> const&) (rbtree_algorithms.hpp:225) ==12425== by 0x4046B4: boost::intrusive::bstbase3, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase3(boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:103) ==12425== by 0x40418F: boost::intrusive::bstbase2, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase2(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:227) ==12425== by 0x403D8E: boost::intrusive::bstbase_hack, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, true, unsigned long, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase_hack(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:466) ==12425== by 0x4039B6: boost::intrusive::bstbase, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, true, unsigned long, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:524) ==12425== by 0x403354: boost::intrusive::bstree_impl, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, unsigned long, true, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstree_impl(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:630) ==12425== by 0x402C32: boost::intrusive::multiset_impl, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, unsigned long, true, boost::intrusive::detail::default_header_holder, true> > >::multiset_impl(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (set.hpp:555) ==12425== by 0x402917: boost::interprocess::rbtree_best_fit, 0ul>::header_t::header_t() (rbtree_best_fit.hpp:147) ==12425== Address 0x1004025018 is not stack'd, malloc'd or (recently) free'd ==12425== ==12425== ==12425== Process terminating with default action of signal 11 (SIGSEGV) ==12425== Access not within mapped region at address 0x1004025018 ==12425== at 0x403C1A: boost::interprocess::offset_ptr >, long, int, 0ul>::get() const (offset_ptr.hpp:346) ==12425== by 0x4038D5: boost::intrusive::pointer_plus_bits >, long, int, 0ul>, 1ul>::set_pointer(boost::interprocess::offset_ptr >, long, int, 0ul>&, boost::interprocess::offset_ptr >, long, int, 0ul> const&) (offset_ptr.hpp:702) ==12425== by 0x40327C: boost::intrusive::compact_rbtree_node_traits_impl >::set_parent(boost::interprocess::offset_ptr >, long, int, 0ul> const&, boost::interprocess::offset_ptr >, long, int, 0ul> const&) (rbtree_node.hpp:138) ==12425== by 0x403215: boost::intrusive::bstree_algorithms, true> >::init_header(boost::interprocess::offset_ptr >, long, int, 0ul> const&) (bstree_algorithms.hpp:619) ==12425== by 0x404ECB: boost::intrusive::rbtree_algorithms, true> >::init_header(boost::interprocess::offset_ptr >, long, int, 0ul> const&) (rbtree_algorithms.hpp:225) ==12425== by 0x4046B4: boost::intrusive::bstbase3, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase3(boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:103) ==12425== by 0x40418F: boost::intrusive::bstbase2, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase2(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:227) ==12425== by 0x403D8E: boost::intrusive::bstbase_hack, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, true, unsigned long, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase_hack(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:466) ==12425== by 0x4039B6: boost::intrusive::bstbase, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, true, unsigned long, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstbase(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:524) ==12425== by 0x403354: boost::intrusive::bstree_impl, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, unsigned long, true, (boost::intrusive::algo_types)4, boost::intrusive::detail::default_header_holder, true> > >::bstree_impl(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (bstree.hpp:630) ==12425== by 0x402C32: boost::intrusive::multiset_impl, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u>, void, unsigned long, true, boost::intrusive::detail::default_header_holder, true> > >::multiset_impl(std::less, 0ul>::block_ctrl> const&, boost::intrusive::bhtraits, 0ul>::block_ctrl, boost::intrusive::rbtree_node_traits, true>, (boost::intrusive::link_mode_type)0, boost::intrusive::default_tag, 3u> const&) (set.hpp:555) ==12425== by 0x402917: boost::interprocess::rbtree_best_fit, 0ul>::header_t::header_t() (rbtree_best_fit.hpp:147) ==12425== If you believe this happened as a result of a stack ==12425== overflow in your program's main thread (unlikely but ==12425== possible), you can try to increase the size of the ==12425== main thread stack using the --main-stacksize= flag. ==12425== The main thread stack size used in this run was 8388608. ==12425== ==12425== HEAP SUMMARY: ==12425== in use at exit: 36 bytes in 1 blocks ==12425== total heap usage: 3 allocs, 2 frees, 8,796 bytes allocated ==12425== ==12425== LEAK SUMMARY: ==12425== definitely lost: 0 bytes in 0 blocks ==12425== indirectly lost: 0 bytes in 0 blocks ==12425== possibly lost: 36 bytes in 1 blocks ==12425== still reachable: 0 bytes in 0 blocks ==12425== suppressed: 0 bytes in 0 blocks ==12425== Rerun with --leak-check=full to see details of leaked memory ==12425== ==12425== For counts of detected and suppressed errors, rerun with: -v ==12425== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0)