[PATCH] Remove any mention of feature test macro requirements for mmap()
From: John Scott <hidden>
Date: 2022-10-19 13:00:00
Attachments
- signature.asc [application/pgp-signature] 252 bytes
From: John Scott <hidden>
Date: 2022-10-19 13:00:00
I'm not subscribed, please CC me. glibc doesn't require _GNU_SOURCE to expose certain MAP_* constants anymore (MAP_ANONYMOUS being particularly noteworthy among them for being on track for POSIX Issue 8). See this commit: https://sourceware.org/git/?p=glibc.git;a=commit;h=954b8f38958de72c4712088735eb175118f17b51 or my glibc bug report which triggered the change at https://sourceware.org/bugzilla/show_bug.cgi?id=29375 This is because POSIX reserves MAP_ constants to the implementation, so their unconditional visibility in sys/mman.h is always allowed. This is also helpful for portable application writers. Other C libraries like musl already exhibit this behavior. Because mmap() is in a POSIX-specific header already, using it with any combination of MAP_ constants doesn't require feature test macros. Thanks for your consideration