|
Boost Users : |
Subject: Re: [Boost-users] [interprocess] shared_memory_object constructor with create_only parameter
From: Philipp Hamann (philipp.hamann_at_[hidden])
Date: 2010-01-27 04:09:59
Thanks Derek,
I should have read the manual more carefully.
But nevertheless this behaviour is strange.
When one process closes the shared memory, it can not be reopened by
another one? Thus the processes are not independent any more.
Is there a best practice, how to handle this?
I have only one writing process, but several readers. So I call
shared_memory_object::remove only when the writer is destroyed. But I
have to take care, that the readers are destroyed before the writer is
destroyed, otherwise the memory is not freed.
But what to do if I have several writers, which could open and close the
shared mem, whenever they like to?
How do you handle this?
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