GithubHelp home page GithubHelp logo

bipstruct's Introduction

BIPStruct

Boost IPC Tester

bipstruct's People

Contributors

johnco3 avatar

Watchers

 avatar

bipstruct's Issues

read access violation

The following technique to insert a Name/value into the database works:

db[Shared::String("one", mgr)] = MyPodStruct{ std::allocator_arg, mgr, 1, 20, Bytes{ 7, 8, 9 } };

but the following does not

db.emplace(pw, forward_as_tuple("one"), forward_as_tuple(1, 2, Bytes{ 1, 2 }));

as it results in a read access violation. Details as follows.

Exception thrown at 0x00007FFE0222A839 in bipstruct.exe: Microsoft C++ exception: 
boost::interprocess::interprocess_exception at memory location 0x00000019D6AFDEC0.
Exception thrown: read access violation.
**boost::forward<std::allocator_arg_t const & __ptr64>**(...) returned 0x1234.

Looks like the source of the problem is deep inside boost's allocator_traits.hpp

#if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)
	  template<class T, class ...Args>
	  BOOST_CONTAINER_FORCEINLINE static void priv_construct(dtl::true_type, Allocator &a, T *p, BOOST_FWD_REF(Args) ...args)
	  {  a.construct( p, ::boost::forward<Args>(args)...);  }

	  template<class T, class ...Args>
	  BOOST_CONTAINER_FORCEINLINE static void priv_construct(dtl::false_type, Allocator &, T *p, BOOST_FWD_REF(Args) ...args)
	  {  ::new((void*)p, boost_container_new_t()) T(::boost::forward<Args>(args)...); }
#else // #if !defined(BOOST_NO_CXX11_VARIADIC_TEMPLATES)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.