[svn-commits] tzafrir: branch 1.2 r2689 - /branches/1.2/zaptel.init

SVN commits to the Digium repositories svn-commits at lists.digium.com
Wed Jul 4 14:00:51 CDT 2007


Author: tzafrir
Date: Wed Jul  4 14:00:51 2007
New Revision: 2689

URL: http://svn.digium.com/view/zaptel?view=rev&rev=2689
Log:
Bourne shell scripts should not use >& . dash doesn't support it.
And all of them simply supressed errors, so they were replaced with
2> /dev/null .

Modified:
    branches/1.2/zaptel.init

Modified: branches/1.2/zaptel.init
URL: http://svn.digium.com/view/zaptel/branches/1.2/zaptel.init?view=diff&rev=2689&r1=2688&r2=2689
==============================================================================
--- branches/1.2/zaptel.init (original)
+++ branches/1.2/zaptel.init Wed Jul  4 14:00:51 2007
@@ -174,7 +174,7 @@
 	# zaphpec_enable properly installed
 	if [ $system = debian ]; then
 		echo -n "Running zaphpec_enable: "
-		/usr/sbin/zaphpec_enable >& /dev/null
+		/usr/sbin/zaphpec_enable 2> /dev/null
 	elif [ $system = redhat ]; then
 		action "Running zaphpec_enable: " /usr/sbin/zaphpec_enable
 	fi
@@ -205,12 +205,12 @@
 case "$1" in
   start)
 	# Load drivers
-	rmmod wcusb >& /dev/null
-	rmmod wcfxsusb >& /dev/null
-	rmmod audio >& /dev/null
+	rmmod wcusb 2> /dev/null
+	rmmod wcfxsusb 2> /dev/null
+	rmmod audio 2> /dev/null
 	if [ $system = debian ]; then
 	    echo -n "Loading zaptel framework: " 
-	    modprobe zaptel ${ARGS} >& /dev/null && echo -n "done"
+	    modprobe zaptel ${ARGS} 2> /dev/null && echo -n "done"
 	    echo "."
 	elif [ $system = redhat ]; then
 	    action "Loading zaptel framework: " modprobe zaptel ${ARGS}
@@ -229,7 +229,7 @@
 	echo -n "Loading zaptel hardware modules:"
 	for x in $MODULES; do 
 		eval localARGS="\$${x}_ARGS"
-		if modprobe ${x} ${ARGS} ${localARGS} >& /dev/null; then
+		if modprobe ${x} ${ARGS} ${localARGS} 2> /dev/null; then
 			echo -n " $x"
 			echo "."
 		fi
@@ -244,11 +244,11 @@
 	
 	if [ ! -e /proc/zaptel/1 ]; then
 		echo "No functioning zap hardware found in /proc/zaptel, loading ztdummy"
-		modprobe ztdummy >& /dev/null
+		modprobe ztdummy 2> /dev/null
 	fi
 	if [ $system = debian ]; then
 	    echo -n "Running ztcfg: " 
-	    $ZTCFG >& /dev/null && echo -n "done"
+	    $ZTCFG 2> /dev/null && echo -n "done"
 	    echo "."
 	elif [ $system = redhat ]; then
 	    action "Running ztcfg: " $ZTCFG
@@ -281,7 +281,7 @@
   reload)
 	if [ $system = debian ]; then
 	    echo -n "Reloading ztcfg: "
-	    $ZTCFG >& /dev/null && echo -n "done"
+	    $ZTCFG 2> /dev/null && echo -n "done"
 	    echo "."
 	elif [ $system = redhat ]; then
 	    action "Reloading ztcfg: " $ZTCFG




More information about the svn-commits mailing list