]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
privsep: Allow madvise for musl.
authorRoy Marples <roy@marples.name>
Thu, 23 Feb 2023 00:21:14 +0000 (00:21 +0000)
committerRoy Marples <roy@marples.name>
Thu, 23 Feb 2023 00:21:14 +0000 (00:21 +0000)
Fixes #186.

src/privsep-linux.c

index 6a3019505fe9c96f074193aeb5a9797f11196fb0..2c54152163b0a5cea803bdb3da405f3e886a500e 100644 (file)
@@ -351,6 +351,9 @@ static struct sock_filter ps_seccomp_filter[] = {
        /* SECCOMP BPF is newer than nl80211 so we don't need SIOCGIWESSID
         * which lives in the impossible to include linux/wireless.h header */
 #endif
+#ifdef __NR_madvise /* needed for musl */
+       SECCOMP_ALLOW(__NR_madvise),
+#endif
 #ifdef __NR_mmap
        SECCOMP_ALLOW(__NR_mmap),
 #endif