aboutsummaryrefslogtreecommitdiffstats
path: root/rc.d/init.d/network
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2009-07-29 17:26:33 -0400
committerBill Nottingham <notting@redhat.com>2009-07-30 12:24:33 -0400
commit1096cd2ebc150e5c74b5e8e4016b835f34cd3f48 (patch)
tree5581822887866deec1c54bacb72b732589d0e52f /rc.d/init.d/network
parent48573c2f689c0b7b0aefcb230ce32a7f0fb9d843 (diff)
downloadinitscripts-1096cd2ebc150e5c74b5e8e4016b835f34cd3f48.tar
initscripts-1096cd2ebc150e5c74b5e8e4016b835f34cd3f48.tar.gz
initscripts-1096cd2ebc150e5c74b5e8e4016b835f34cd3f48.tar.bz2
initscripts-1096cd2ebc150e5c74b5e8e4016b835f34cd3f48.tar.xz
initscripts-1096cd2ebc150e5c74b5e8e4016b835f34cd3f48.zip
Use $() instead of `` for process expansion.
Adapted from <victor.lowther@gmail.com>.
Diffstat (limited to 'rc.d/init.d/network')
-rwxr-xr-xrc.d/init.d/network12
1 files changed, 6 insertions, 6 deletions
diff --git a/rc.d/init.d/network b/rc.d/init.d/network
index 7695da46..d38622c6 100755
--- a/rc.d/init.d/network
+++ b/rc.d/init.d/network
@@ -39,7 +39,7 @@ fi
# Even if VLAN is configured, without the utility we can't do much
[ ! -x /sbin/vconfig ] && VLAN=
-CWD=`pwd`
+CWD=$(pwd)
cd /etc/sysconfig/network-scripts
. ./network-functions
@@ -188,9 +188,9 @@ case "$1" in
# If this is a final shutdown/halt, check for network FS,
# and unmount them even if the user didn't turn on netfs
if [ "$RUNLEVEL" = "6" -o "$RUNLEVEL" = "0" -o "$RUNLEVEL" = "1" ]; then
- NFSMTAB=`LC_ALL=C awk '$3 ~ /^nfs/ { print $2 }' /proc/mounts`
- SMBMTAB=`LC_ALL=C awk '$3 == "smbfs" { print $2 }' /proc/mounts`
- NCPMTAB=`LC_ALL=C awk '$3 == "ncpfs" { print $2 }' /proc/mounts`
+ NFSMTAB=$(LC_ALL=C awk '$3 ~ /^nfs/ { print $2 }' /proc/mounts)
+ SMBMTAB=$(LC_ALL=C awk '$3 == "smbfs" { print $2 }' /proc/mounts)
+ NCPMTAB=$(LC_ALL=C awk '$3 == "ncpfs" { print $2 }' /proc/mounts)
if [ -n "$NFSMTAB" -o -n "$SMBMTAB" -o -n "$NCPMTAB" ] ; then
/etc/init.d/netfs stop
fi
@@ -263,12 +263,12 @@ case "$1" in
if [ -d /proc/sys/net/ipv4 ]; then
if [ -f /proc/sys/net/ipv4/ip_forward ]; then
- if [ `cat /proc/sys/net/ipv4/ip_forward` != 0 ]; then
+ if [ $(cat /proc/sys/net/ipv4/ip_forward) != 0 ]; then
action $"Disabling IPv4 packet forwarding: " sysctl -w net.ipv4.ip_forward=0
fi
fi
if [ -f /proc/sys/net/ipv4/ip_always_defrag ]; then
- if [ `cat /proc/sys/net/ipv4/ip_always_defrag` != 0 ]; then
+ if [ $(cat /proc/sys/net/ipv4/ip_always_defrag) != 0 ]; then
action $"Disabling IPv4 automatic defragmentation: " sysctl -w net.ipv4.ip_always_defrag=0
fi
fi