aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2002-04-13 01:18:49 +0000
committerBill Nottingham <notting@redhat.com>2002-04-13 01:18:49 +0000
commit3e9972c739d10444be70c3fe603aef9612435ef9 (patch)
tree473fc7251553d5c18913e7cd6914fa4df334ca6f
parent03d37167e2b31be3c3220a47e27e0258e0a398f9 (diff)
downloadinitscripts-3e9972c739d10444be70c3fe603aef9612435ef9.tar
initscripts-3e9972c739d10444be70c3fe603aef9612435ef9.tar.gz
initscripts-3e9972c739d10444be70c3fe603aef9612435ef9.tar.bz2
initscripts-3e9972c739d10444be70c3fe603aef9612435ef9.tar.xz
initscripts-3e9972c739d10444be70c3fe603aef9612435ef9.zip
fix always trying to shut down 6to4 (#63352, <pekkas@netcore.fi>)
-rwxr-xr-xsysconfig/network-scripts/ifdown-ipv613
1 files changed, 9 insertions, 4 deletions
diff --git a/sysconfig/network-scripts/ifdown-ipv6 b/sysconfig/network-scripts/ifdown-ipv6
index 23084670..41026b5b 100755
--- a/sysconfig/network-scripts/ifdown-ipv6
+++ b/sysconfig/network-scripts/ifdown-ipv6
@@ -11,7 +11,7 @@
#
# RHL integration assistance by Pekka Savola <pekkas@netcore.fi>
#
-# Version 2002-01-25
+# Version 2002-04-12
#
# Note: if called as (like normally) by /etc/sysconfig/network-scripts/ifdown
# exit codes aren't handled by "ifdown"
@@ -100,10 +100,15 @@ fi
# Get local IPv4 address of dedicated tunnel
ipv4addr6to4local="`ipv6_get_ipv4addr_of_tunnel tun6to4 local`"
-# Check against configured 6to4 tunnel to see if this interface was used before
-if [ "$ipv4addr" != "$ipv4addr6to4local" ]; then
- # IPv4 address of interface does't match local tunnel address, interface was not used for current 6to4 setup
+if [ -z "$ipv4addr" -o -z "$ipv4addr6to4local" ]; then
+ # no IPv4 addresses given, 6to4 sure not configured
valid6to4config="no"
+else
+ # Check against configured 6to4 tunnel to see if this interface was used before
+ if [ "$ipv4addr" != "$ipv4addr6to4local" ]; then
+ # IPv4 address of interface does't match local tunnel address, interface was not used for current 6to4 setup
+ valid6to4config="no"
+ fi
fi
# Shutdown of 6to4, if configured