diff options
author | Antoine Jacoutot <ajacoutot@cvs.openbsd.org> | 2017-05-28 18:51:28 +0000 |
---|---|---|
committer | Antoine Jacoutot <ajacoutot@cvs.openbsd.org> | 2017-05-28 18:51:28 +0000 |
commit | 3557910fd071030ea23a8287871f02f13095cbe0 (patch) | |
tree | 0139de41f9edc8e3e16d14478289596a7acb6406 /etc/rc.d | |
parent | 384814f1e47b883620d60faeb8e40b32bfd73207 (diff) |
Move check later to mitigate a possible race.
Diffstat (limited to 'etc/rc.d')
-rw-r--r-- | etc/rc.d/rc.subr | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/rc.d/rc.subr b/etc/rc.d/rc.subr index 041540f4f09..49f9f233e6d 100644 --- a/etc/rc.d/rc.subr +++ b/etc/rc.d/rc.subr @@ -1,4 +1,4 @@ -# $OpenBSD: rc.subr,v 1.123 2017/05/28 10:12:42 ajacoutot Exp $ +# $OpenBSD: rc.subr,v 1.124 2017/05/28 18:51:27 ajacoutot Exp $ # # Copyright (c) 2010, 2011, 2014-2017 Antoine Jacoutot <ajacoutot@openbsd.org> # Copyright (c) 2010, 2011 Ingo Schwarze <schwarze@openbsd.org> @@ -223,9 +223,9 @@ rc_cmd() { _rc_do rc_start; _ret=$? kill -ALRM ${_TIMERSUB} wait ${_TIMERSUB} 2>/dev/null # don't print Alarm clock - [[ "${_ret}" == @(0|142) ]] && _rc_do rc_check || break [[ "${_ret}" == 142 ]] && [ X"${rc_bg}" != X"YES" ] && _to="timeout" + [[ "${_ret}" == @(0|142) ]] && _rc_do rc_check || break _rc_do _rc_write_runfile _rc_exit ${_to:=ok} done |