From c3e9a7ec14b1120ecae7b9e4a2125dda01eec9b7 Mon Sep 17 00:00:00 2001 From: Roy Marples Date: Mon, 1 Jun 2009 20:10:42 +0100 Subject: Warn about going inactive correctly. --- src/rc/runscript.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'src/rc') diff --git a/src/rc/runscript.c b/src/rc/runscript.c index 44da58c5..91a31a59 100644 --- a/src/rc/runscript.c +++ b/src/rc/runscript.c @@ -755,13 +755,10 @@ static void svc_start_real() if (ibsave) unsetenv("IN_BACKGROUND"); - if (!started) + if (rc_service_state(service) & RC_SERVICE_INACTIVE) + ewarnx("WARNING: %s has started, but is inactive", applet); + else if (!started) eerrorx("ERROR: %s failed to start", applet); - else { - if (rc_service_state(service) & RC_SERVICE_INACTIVE) - ewarnx("WARNING: %s has started, but is inactive", - applet); - } rc_service_mark(service, RC_SERVICE_STARTED); exclusive_fd = svc_unlock(applet, exclusive_fd); -- cgit v1.2.3