From: Roy Marples Date: Wed, 8 Jan 2020 14:26:01 +0000 (+0000) Subject: Linux: clean up some compile warnings without privsep X-Git-Tag: v9.0.0~135 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=28df98fe7eb6966b547ec73836ca525fb0969608;p=thirdparty%2Fdhcpcd.git Linux: clean up some compile warnings without privsep --- diff --git a/src/if-linux.c b/src/if-linux.c index 175d5246..d5dfdeda 100644 --- a/src/if-linux.c +++ b/src/if-linux.c @@ -256,6 +256,8 @@ if_writepathuint(struct dhcpcd_ctx *ctx, const char *path, unsigned int val) #ifdef PRIVSEP if (ctx->options & DHCPCD_PRIVSEP) return ps_root_writepathuint(ctx, path, val); +#else + UNUSED(ctx); #endif fp = fopen(path, "w"); @@ -927,6 +929,7 @@ if_handlelink(struct dhcpcd_ctx *ctx) &link_netlink, NULL); } +#ifdef PRIVSEP static bool if_netlinkpriv(int protocol, struct nlmsghdr *nlm) { @@ -945,6 +948,7 @@ if_netlinkpriv(int protocol, struct nlmsghdr *nlm) return false; } } +#endif static int if_sendnetlink(struct dhcpcd_ctx *ctx, int protocol, struct nlmsghdr *hdr,