|
Boost Users : |
Subject: Re: [Boost-users] How to keep a pointer on a shared data in a boost shared memory segment
From: Ion Gaztañaga (igaztanaga_at_[hidden])
Date: 2019-03-23 18:49:09
On 20/03/2019 13:03, jucin loic via Boost-users wrote:
> Hi everyone !
> How to keep a pointer on a shared data in a boost shared memory segment
> ? I have a function which returns
> shm.construct<SharedData>(_nameSeg.c_str())(innerDataAllocator); But
> outside of the function, the object pointed by SharedData is inaccessible
> My general problem is that I want to have way to get, and set data in
> shared memory, but without, each time, having to :
> -get shm
> -find object in shm based on its name
> -construct allocators.
> So I would like to store 1) allocators and 2)a pointer to the shared object
> How could I do this ?
> I made a SO question about my problem, can you have a look ? It should
> be clearer :)
> https://stackoverflow.com/questions/55195149/how-to-keep-a-pointer-on-a-shared-data-in-a-boost-shared-memory-segment
I'm afraid I don't understand the problem, and your minimal example
needs password. Could you send a single cpp file with the minimal code
to understand your question?
Best,
Ion
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net