summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2012-02-18 00:46:18 +0000
committerdelphij <delphij@FreeBSD.org>2012-02-18 00:46:18 +0000
commitec9c1986ab8dd4f1269f10b5f0fc10b21fb86770 (patch)
tree01965551ed38210827c56c733b6c018b25483089 /etc
parentabd1094f175810ed5ec686a897d27fae63d1ca87 (diff)
downloadFreeBSD-src-ec9c1986ab8dd4f1269f10b5f0fc10b21fb86770.zip
FreeBSD-src-ec9c1986ab8dd4f1269f10b5f0fc10b21fb86770.tar.gz
Put the signal trap output to standard error instead of standard output.
Without this change, pressing ^T could result in rc.d script putting junk strings like: Script <filename> running in configuration files when redirecting standard output to these files. MFC after: 2 weeks
Diffstat (limited to 'etc')
-rw-r--r--etc/rc.subr6
1 files changed, 3 insertions, 3 deletions
diff --git a/etc/rc.subr b/etc/rc.subr
index e629bc7..4c445a0 100644
--- a/etc/rc.subr
+++ b/etc/rc.subr
@@ -985,9 +985,9 @@ run_rc_script()
if [ -n "$rc_fast_and_loose" ]; then
set $_arg; . $_file
else
- ( trap "echo Script $_file interrupted; kill -QUIT $$" 3
- trap "echo Script $_file interrupted; exit 1" 2
- trap "echo Script $_file running" 29
+ ( trap "echo Script $_file interrupted >&2 ; kill -QUIT $$" 3
+ trap "echo Script $_file interrupted >&2 ; exit 1" 2
+ trap "echo Script $_file running >&2" 29
set $_arg; . $_file )
fi
fi
OpenPOWER on IntegriCloud