You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Mike Behne <md...@yahoo.com> on 2006/04/07 18:17:52 UTC
shared memory among multiple users
I have been using apr_shm_create and apr_shm_attach on Windows with good results--as long as all processes referencing the memory run under the same account. I've run into trouble in a case where the shared memory is created under one account, and then an attempt is made to reference from another process running under a different account. In this case the apr_shm_attach returns "720005"--access denied. Looking at the underlying Windows functions, it looks like there are ways to specify access lists for the mapped file, but the apr functions do not provide a way to utilize this. Am I missing something? Is there a way to share memory between processes running under different accounts with apr_shm?
---------------------------------
Blab-away for as little as 1ยข/min. Make PC-to-Phone Calls using Yahoo! Messenger with Voice.
Re: shared memory among multiple users
Posted by Garrett Rooney <ro...@electricjellyfish.net>.
On 4/7/06, Mike Behne <md...@yahoo.com> wrote:
> I have been using apr_shm_create and apr_shm_attach on Windows with good
> results--as long as all processes referencing the memory run under the same
> account. I've run into trouble in a case where the shared memory is created
> under one account, and then an attempt is made to reference from another
> process running under a different account. In this case the apr_shm_attach
> returns "720005"--access denied. Looking at the underlying Windows
> functions, it looks like there are ways to specify access lists for the
> mapped file, but the apr functions do not provide a way to utilize this. Am
> I missing something? Is there a way to share memory between processes
> running under different accounts with apr_shm?
That may be one of those things that's difficult to do portably... If
you can come up with an API that could be implemented on multiple
platforms I'm sure we'd be willing to add it, but at this point I
would not be surprised if the functionality did not exist in APR.
-garrett