Hi all,
the POSIX standard doesn't mandate that IPC_PRIVATE has any particular
value; in practise it is often (maybe always) zero, but I think the
constant is important enough to deserve its own PHP userland constant.
It would be useful for shmop_open(), shm_attach() and sem_get(), but
these three functions belong to three different extensions (shmop,
sysvshm, sysvsem), so it is not clear where to define the constant, and
how to name it.
My first thought was to define PHP_IPC_PRIVATE
in main.c, but Nikita
had reasonable objections to expose the constant from core. I came up
with a somewhat doubtful alternative[1]; a maybe even worse alternative
would be to define three separate constants.
Has anybody an idea how to solve that? Of course, you could also
comment on https://github.com/php/php-src/pull/5527 directly.
[1]
https://github.com/php/php-src/pull/5527/commits/a33d2f3921e53810873e6cbb7856234e24520ab8
Thanks,
Christoph