1
0
mirror of https://github.com/openbsd/src.git synced 2024-12-22 16:42:56 -08:00

fix fd leak on SIGHUP after config change, spotted by Stephen Marley; ok avsm@

This commit is contained in:
djm 2005-06-06 23:20:44 +00:00
parent 06674ba363
commit 4dfa96bc11

View File

@ -1,4 +1,4 @@
/* $OpenBSD: privsep.c,v 1.25 2005/05/23 20:12:28 henning Exp $ */
/* $OpenBSD: privsep.c,v 1.26 2005/06/06 23:20:44 djm Exp $ */
/*
* Copyright (c) 2003 Anil Madhavapeddy <anil@recoil.org>
@ -326,6 +326,8 @@ priv_init(char *conf, int numeric, int lockfd, int nullfd, char *argv[])
}
}
close(socks[0]);
/* Unlink any domain sockets that have been opened */
for (i = 0; i < nfunix; i++)
if (funixn[i] != NULL && pfd[PFD_UNIX_0 + i].fd != -1)