Favor siginfo_t over struct siginfo

This commit is contained in:
Justine Tunney 2024-05-28 02:34:17 -07:00
parent c638eabfe0
commit deaef81463
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
20 changed files with 37 additions and 39 deletions

View file

@ -5,7 +5,7 @@
COSMOPOLITAN_C_START_
typedef void (*sighandler_t)(int);
typedef void (*sigaction_f)(int, struct siginfo *, void *);
typedef void (*sigaction_f)(int, siginfo_t *, void *);
struct sigaction {
union {

View file

@ -60,11 +60,11 @@ union metasigaction {
struct sigaction_xnu_out xnu_out;
};
void __sigenter_xnu(int, struct siginfo *, void *);
void __sigenter_wsl(int, struct siginfo *, void *);
void __sigenter_netbsd(int, struct siginfo *, void *);
void __sigenter_freebsd(int, struct siginfo *, void *);
void __sigenter_openbsd(int, struct siginfo *, void *);
void __sigenter_xnu(int, siginfo_t *, void *);
void __sigenter_wsl(int, siginfo_t *, void *);
void __sigenter_netbsd(int, siginfo_t *, void *);
void __sigenter_freebsd(int, siginfo_t *, void *);
void __sigenter_openbsd(int, siginfo_t *, void *);
const char *DescribeSigaction(char[256], int, const struct sigaction *);
#define DescribeSigaction(rc, sa) DescribeSigaction(alloca(256), rc, sa)

View file

@ -8,14 +8,14 @@
COSMOPOLITAN_C_START_
union siginfo_meta {
struct siginfo linux;
siginfo_t linux;
struct siginfo_xnu xnu;
struct siginfo_freebsd freebsd;
struct siginfo_openbsd openbsd;
struct siginfo_netbsd netbsd;
};
void __siginfo2cosmo(struct siginfo *, const union siginfo_meta *);
void __siginfo2cosmo(siginfo_t *, const union siginfo_meta *);
COSMOPOLITAN_C_END_
#endif /* COSMOPOLITAN_LIBC_CALLS_STRUCT_SIGINFO_META_INTERNAL_H_ */