diff options
author | Reyk Floeter <reyk@cvs.openbsd.org> | 2005-04-13 21:15:37 +0000 |
---|---|---|
committer | Reyk Floeter <reyk@cvs.openbsd.org> | 2005-04-13 21:15:37 +0000 |
commit | d0ce38bc9b74fae350509cf7e5be7fe308e49204 (patch) | |
tree | 4a8f1334515e99f58fb0af054769166ac200d1d0 /usr.sbin/hostapd/privsep.c | |
parent | 4b6fcb58281e0581b34105566467ba4525578917 (diff) |
un-hack, use event_loopexit()
ok henning@ brad@
Diffstat (limited to 'usr.sbin/hostapd/privsep.c')
-rw-r--r-- | usr.sbin/hostapd/privsep.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/usr.sbin/hostapd/privsep.c b/usr.sbin/hostapd/privsep.c index 849be5a868a..f4221208709 100644 --- a/usr.sbin/hostapd/privsep.c +++ b/usr.sbin/hostapd/privsep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: privsep.c,v 1.8 2005/04/13 21:02:44 moritz Exp $ */ +/* $OpenBSD: privsep.c,v 1.9 2005/04/13 21:15:36 reyk Exp $ */ /* * Copyright (c) 2004, 2005 Reyk Floeter <reyk@vantronix.net> @@ -69,9 +69,6 @@ void hostapd_must_write(int, void *, size_t); static int priv_fd = -1; static volatile pid_t child_pid = -1; -/* defined in event(3) to terminate the event loop */ -extern volatile sig_atomic_t event_gotterm; - /* * Main privsep functions */ @@ -377,13 +374,17 @@ hostapd_sig_relay(int sig) void hostapd_sig_chld(int sig) { + struct timeval tv; + + tv.tv_sec = 0; + tv.tv_usec = 0; + /* * If parent gets a SIGCHLD, it will exit. */ if (sig == SIGCHLD) { - /* This will terminate libevent's main loop */ - event_gotterm = 1; + event_loopexit(&tv); } } |