aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig
diff options
context:
space:
mode:
Diffstat (limited to 'sysconfig')
-rwxr-xr-xsysconfig/network-scripts/ifup2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysconfig/network-scripts/ifup b/sysconfig/network-scripts/ifup
index 48f15201..eb532d43 100755
--- a/sysconfig/network-scripts/ifup
+++ b/sysconfig/network-scripts/ifup
@@ -200,7 +200,7 @@ if [ -n "${DYNCONFIG}" ]; then
NUMDEFROUTES=`ip -o route | \
grep "^default" | \
awk '{ nlines++ } END { print nlines }'`
- if [ "$NUMDEFROUTES" -gt 1 ]; then
+ if [ -n "$NUMDEFROUTES" -a "$NUMDEFROUTES" -gt 1 ]; then
# remove the default route for the new device (old route wins)
ip route del default dev ${DEVICE}
fi