Check if no signals were delivered just before going to sleep.

MFC after:	2 weeks
Obtained from:	Wheel Systems Sp. z o.o. http://www.wheelsystems.com
This commit is contained in:
Pawel Jakub Dawidek 2010-08-27 20:49:06 +00:00
parent 01125a9381
commit eba09893fd
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=211896

View File

@ -1988,7 +1988,9 @@ guard_thread(void *arg)
rw_unlock(&hio_remote_lock[ii]);
}
}
(void)cv_timedwait(&hio_guard_cond, &hio_guard_lock, timeout);
/* Sleep only if a signal wasn't delivered in the meantime. */
if (!sigexit_received && !sighup_received && !sigchld_received)
cv_timedwait(&hio_guard_cond, &hio_guard_lock, timeout);
mtx_unlock(&hio_guard_lock);
}
/* NOTREACHED */