Re: Posix shared memory problem
- From: Jilles Tjoelker <jilles@xxxxxxxx>
- Date: Sat, 9 May 2009 22:07:24 +0200
On Sat, May 09, 2009 at 08:31:15PM +0200, Lothar Scholz wrote:
Thanks for solving the posix semaphore problem. But with shared memory
there comes the next issue:
int main() {
int m;
shm_unlink("/barfoo");
m = shm_open("/barfoo", O_RDWR|O_CREAT|O_EXCL, S_IRWXU);
if (m == 1) perror("shm_open error");
}
i always get permission denied error, and i tried many values
for flags and mode? I can only get this working as root but not
as a normal user.
shm_open/shm_unlink refer to the filesystem; they are fairly direct
wrappers around open and unlink.
POSIX suggests making the pathname a configuration option;
alternatively, using a directory for temporary files such as /tmp could
work.
--
Jilles Tjoelker
_______________________________________________
freebsd-arch@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-arch
To unsubscribe, send any mail to "freebsd-arch-unsubscribe@xxxxxxxxxxx"
- Follow-Ups:
- Re[2]: Posix shared memory problem
- From: Lothar Scholz
- Re: Posix shared memory problem
- From: Ed Schouten
- Re[2]: Posix shared memory problem
- References:
- Posix shared memory problem
- From: Lothar Scholz
- Posix shared memory problem
- Prev by Date: Re[2]: Are named posix semaphores not implemented?
- Next by Date: Re: Posix shared memory problem
- Previous by thread: Posix shared memory problem
- Next by thread: Re: Posix shared memory problem
- Index(es):
Relevant Pages
|