Provide fallback definitions for SHM_EXEC constant

Although SHM_EXEC is available in <linux/shm.h> since kernel commit
v2.6.9-rc2~23^2~93^2~78, the glibc version of <sys/shm.h> did not
provide SHM_EXEC until commit glibc-2.10~238.

* xlat/shm_flags.in (SHM_EXEC): Add fallback definition.
* tests/shmxt.c (SHM_EXEC): Likewise.
This commit is contained in:
Дмитрий Левин 2017-11-17 11:26:55 +00:00
parent bdc500a563
commit 1abb9ffd20
2 changed files with 5 additions and 1 deletions

View File

@ -18,6 +18,10 @@ cleanup(void)
# define SHMAT "shmat"
#endif
#ifndef SHM_EXEC
# define SHM_EXEC 0100000
#endif
int
main(void)
{

View File

@ -1,4 +1,4 @@
SHM_RDONLY
SHM_RND
SHM_REMAP
SHM_EXEC
SHM_EXEC 0100000