svn commit: r232434 - stable/9/etc

Xin LI delphij at FreeBSD.org
Sat Mar 3 02:35:46 UTC 2012


Author: delphij
Date: Sat Mar  3 02:35:45 2012
New Revision: 232434
URL: http://svn.freebsd.org/changeset/base/232434

Log:
  MFC r231888:
  
  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.

Modified:
  stable/9/etc/rc.subr
Directory Properties:
  stable/9/etc/   (props changed)

Modified: stable/9/etc/rc.subr
==============================================================================
--- stable/9/etc/rc.subr	Sat Mar  3 02:23:09 2012	(r232433)
+++ stable/9/etc/rc.subr	Sat Mar  3 02:35:45 2012	(r232434)
@@ -1027,9 +1027,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


More information about the svn-src-stable-9 mailing list