SVN: rc-scripts/trunk/sysconfig/network-scripts/functions.network

glen glen at pld-linux.org
Sun Oct 28 17:13:04 CET 2007


Author: glen
Date: Sun Oct 28 17:13:04 2007
New Revision: 8884

Modified:
   rc-scripts/trunk/sysconfig/network-scripts/functions.network
Log:
- no need for LC_ALL=C to grep fixed string

Modified: rc-scripts/trunk/sysconfig/network-scripts/functions.network
==============================================================================
--- rc-scripts/trunk/sysconfig/network-scripts/functions.network	(original)
+++ rc-scripts/trunk/sysconfig/network-scripts/functions.network	Sun Oct 28 17:13:04 2007
@@ -540,23 +540,23 @@
 {
 	[ -x /sbin/mii-tool ] || return 2
 	output=$(LC_ALL=C mii-tool $1 2>&1)
-	echo $output | LC_ALL=C grep -q "link ok" && return 1
-	echo $output | LC_ALL=C grep -q "no link" && return 0 || return 2
+	echo $output | grep -q "link ok" && return 1
+	echo $output | grep -q "no link" && return 0 || return 2
 }
 
 check_ethtool ()
 {
 	[ -x /sbin/ethtool ] || return 2
 	output=$(LC_ALL=C ethtool $1 2>&1)
-	echo $output | LC_ALL=C grep -q "Link detected: yes" && return 1
-	echo $output | LC_ALL=C grep -q "Link detected: no" && return 0 || return 2
+	echo $output | grep -q "Link detected: yes" && return 1
+	echo $output | grep -q "Link detected: no" && return 0 || return 2
 }
 
 check_iwconfig ()
 {
 	[ -x /sbin/iwconfig ] || return 2
 	output=$(LC_ALL=C iwconfig $1 2>&1)
-	echo $output | LC_ALL=C grep -q "radio off" && return 0 || return 2
+	echo $output | grep -q "radio off" && return 0 || return 2
 }
 
 check_link_down ()


More information about the pld-cvs-commit mailing list