[Bug 275328] <signal.h> fails to expose SA_* macros without XSI
Date: Sat, 25 Nov 2023 10:35:34 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275328 Bug ID: 275328 Summary: <signal.h> fails to expose SA_* macros without XSI Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: standards Assignee: standards@FreeBSD.org Reporter: jbeich@FreeBSD.org According to POSIX.1-2008: > Issue 7 [...] > The SA_RESETHAND, SA_RESTART, SA_SIGINFO, SA_NOCLDWAIT, and SA_NODEFER constants are moved from the XSI option to the Base. https://pubs.opengroup.org/onlinepubs/9699919799.2008edition/basedefs/signal.h.html https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/signal.h.html which doesn't seem to work on FreeBSD: $ cc a.c a.c:6:39: error: use of undeclared identifier 'SA_RESTART' 6 | struct sigaction sa = { .sa_flags = SA_RESTART, /* .sa_handler = myfunc */ }; | ^ 1 error generated. #define _POSIX_C_SOURCE 200809L #include <signal.h> int main() { struct sigaction sa = { .sa_flags = SA_RESTART, /* .sa_handler = myfunc */ }; } -- You are receiving this mail because: You are the assignee for the bug.