diff options
author | des <des@FreeBSD.org> | 2015-04-26 11:23:26 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2015-04-26 11:23:26 +0000 |
commit | fe0c01d26579d19ddf439fb46ef0bd3cc2bc7f4c (patch) | |
tree | 01c1d94467622a175fad10cd34a2f6f05d32c1b7 /daemon/unbound.c | |
parent | cabe860377233bc13a6d101fdb59bb834cab980a (diff) | |
download | FreeBSD-src-fe0c01d26579d19ddf439fb46ef0bd3cc2bc7f4c.zip FreeBSD-src-fe0c01d26579d19ddf439fb46ef0bd3cc2bc7f4c.tar.gz |
import unbound 1.5.2
Diffstat (limited to 'daemon/unbound.c')
-rw-r--r-- | daemon/unbound.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/daemon/unbound.c b/daemon/unbound.c index a31b039..f6bd924 100644 --- a/daemon/unbound.c +++ b/daemon/unbound.c @@ -504,16 +504,18 @@ perform_setup(struct daemon* daemon, struct config_file* cfg, int debug_mode, if(cfg->pidfile && cfg->pidfile[0]) { writepid(daemon->pidfile, getpid()); if(cfg->username && cfg->username[0]) { +# ifdef HAVE_CHOWN if(chown(daemon->pidfile, cfg->uid, cfg->gid) == -1) { log_err("cannot chown %u.%u %s: %s", (unsigned)cfg->uid, (unsigned)cfg->gid, daemon->pidfile, strerror(errno)); } +# endif /* HAVE_CHOWN */ } } #else (void)daemon; -#endif +#endif /* HAVE_KILL */ /* Set user context */ #ifdef HAVE_GETPWNAM |