From 817112796b8095026d2e6551fef66618450acf98 Mon Sep 17 00:00:00 2001 From: Antoine Jacoutot Date: Mon, 17 Nov 2014 13:52:45 +0000 Subject: "reload" should fail if the service is not running in the first place. ok robert@ sthen@ --- etc/rc.d/rc.subr | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'etc') diff --git a/etc/rc.d/rc.subr b/etc/rc.d/rc.subr index 583d9ce9363..0c9c7dc2afc 100644 --- a/etc/rc.d/rc.subr +++ b/etc/rc.d/rc.subr @@ -1,4 +1,4 @@ -# $OpenBSD: rc.subr,v 1.89 2014/08/30 20:33:27 ajacoutot Exp $ +# $OpenBSD: rc.subr,v 1.90 2014/11/17 13:52:44 ajacoutot Exp $ # # Copyright (c) 2010, 2011, 2014 Antoine Jacoutot # Copyright (c) 2010, 2011 Ingo Schwarze @@ -226,9 +226,8 @@ rc_cmd() { _rc_exit ok ;; reload) - _rc_do rc_check || exit 0 echo $_n "${INRC:+ }${_name}" - _rc_do rc_reload || _rc_exit failed + _rc_do rc_check && _rc_do rc_reload || _rc_exit failed _rc_do _rc_wait reload || _rc_exit failed _rc_exit ok ;; -- cgit v1.2.3