From 807a7f34cd58c537d8b361694d0a4bad23d8aff9 Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Tue, 25 Oct 2011 15:32:53 -0400 Subject: Don't write to stderr that's not there (or a socket, or whatever, #746263) --- service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'service') diff --git a/service b/service index 6f179347..2e2d4ea6 100755 --- a/service +++ b/service @@ -69,6 +69,6 @@ done if [ -f "${SERVICEDIR}/${SERVICE}" ]; then env -i PATH="$PATH" TERM="$TERM" SYSTEMCTL_IGNORE_DEPENDENCIES=${SYSTEMCTL_IGNORE_DEPENDENCIES} SYSTEMCTL_SKIP_REDIRECT=${SYSTEMCTL_SKIP_REDIRECT} "${SERVICEDIR}/${SERVICE}" ${OPTIONS} else - echo $"Redirecting to /bin/systemctl ${OPTIONS} ${SERVICE}.service" >/dev/stderr + [ -c /dev/stderr ] && echo $"Redirecting to /bin/systemctl ${OPTIONS} ${SERVICE}.service" >/dev/stderr exec /bin/systemctl ${OPTIONS} ${SERVICE}.service fi -- cgit v1.2.1