diff options
| author | Roy Marples <roy@marples.name> | 2020-05-20 12:23:25 +0100 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2020-05-20 12:23:25 +0100 |
| commit | ed42d4f666a2d6a03f8ae901dd864b8db39c635c (patch) | |
| tree | 251d83467ac9df94ee2befeb8f4a91246a72b64e /src/ipv6.c | |
| parent | b060ddf2bc7e7f4d3302a1c708394d758b52c4b4 (diff) | |
| download | dhcpcd-ed42d4f666a2d6a03f8ae901dd864b8db39c635c.tar.xz | |
OpenBSD: Fix non privsep builds.
Diffstat (limited to 'src/ipv6.c')
| -rw-r--r-- | src/ipv6.c | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -1091,10 +1091,12 @@ ipv6_anyglobal(struct interface *sifp) #ifdef BSD bool forwarding; -#ifdef HAVE_PLEDGE - forwarding = ps_root_ip6forwarding(sifp->ctx) == 1; +#if defined(PRIVSEP) && defined(HAVE_PLEDGE) + if (IN_PRIVSEP(sifp->ctx)) + forwarding = ps_root_ip6forwarding(sifp->ctx) == 1; + else #else - forwarding = ip6_forwarding(NULL) == 1; + forwarding = ip6_forwarding(NULL) == 1; #endif #endif |
