diff options
| author | Roy Marples <roy@marples.name> | 2020-01-08 20:13:20 +0000 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2020-01-08 20:13:20 +0000 |
| commit | 84bb0708e0d5996f010b733fdb68d17bf441e255 (patch) | |
| tree | 4c0f27df4110076994676980475f569ae6dc155d /src/privsep-bpf.c | |
| parent | c55279517dc3df6743100c5e525d464010f563c6 (diff) | |
| download | dhcpcd-84bb0708e0d5996f010b733fdb68d17bf441e255.tar.xz | |
ioctl: The POSIX signature differs from BSD and glibc
BSD and glibc have the signature for request as unsigned long.
musl and Solaris have a signed int.
As such, we need to detect this at compile time and adjust the
signature of our internal ioctl functions to match.
To keep the onwire format the same, memcpy the request to the
unsigned long request and back again, thus preserving the signedness.
Diffstat (limited to 'src/privsep-bpf.c')
| -rw-r--r-- | src/privsep-bpf.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/privsep-bpf.c b/src/privsep-bpf.c index 0985bd2e..bb6ee083 100644 --- a/src/privsep-bpf.c +++ b/src/privsep-bpf.c @@ -40,6 +40,7 @@ #include <assert.h> #include <pwd.h> #include <errno.h> +#include <signal.h> #include <stdlib.h> #include <string.h> #include <unistd.h> |
