aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ppp/ip-down7
-rw-r--r--ppp/ip-up7
-rwxr-xr-xrc.d/init.d/functions2
-rwxr-xr-xsysconfig/network-scripts/ifdown-ipv64
-rwxr-xr-xsysconfig/network-scripts/ifdown-post2
-rwxr-xr-xsysconfig/network-scripts/ifdown-ppp2
-rwxr-xr-xsysconfig/network-scripts/ifdown-sl2
-rwxr-xr-xsysconfig/network-scripts/ifup-ctc2
-rw-r--r--sysconfig/network-scripts/ifup-escon2
-rwxr-xr-xsysconfig/network-scripts/ifup-iucv2
-rwxr-xr-xsysconfig/network-scripts/ifup-plip2
-rwxr-xr-xsysconfig/network-scripts/ifup-plusb2
-rw-r--r--sysconfig/network-scripts/network-functions4
13 files changed, 12 insertions, 28 deletions
diff --git a/ppp/ip-down b/ppp/ip-down
index 70f1aa8f..3c86f2a6 100644
--- a/ppp/ip-down
+++ b/ppp/ip-down
@@ -1,14 +1,13 @@
#!/bin/bash
-
# This file should not be modified -- make local changes to
# /etc/ppp/ip-down.local instead
-LOGDEVICE=$6
-REALDEVICE=$1
-
PATH=/sbin:/usr/sbin:/bin:/usr/bin
export PATH
+LOGDEVICE=$6
+REALDEVICE=$1
+
[ -x /etc/ppp/ip-down.local ] && /etc/ppp/ip-down.local "$@"
/etc/sysconfig/network-scripts/ifdown-post ifcfg-${LOGDEVICE}
diff --git a/ppp/ip-up b/ppp/ip-up
index 47517489..3b73814f 100644
--- a/ppp/ip-up
+++ b/ppp/ip-up
@@ -1,14 +1,13 @@
#!/bin/bash
-
# This file should not be modified -- make local changes to
# /etc/ppp/ip-up.local instead
-LOGDEVICE=$6
-REALDEVICE=$1
-
PATH=/sbin:/usr/sbin:/bin:/usr/bin
export PATH
+LOGDEVICE=$6
+REALDEVICE=$1
+
[ -f /etc/sysconfig/network-scripts/ifcfg-${LOGDEVICE} ] && /etc/sysconfig/network-scripts/ifup-post ifcfg-${LOGDEVICE}
[ -x /etc/ppp/ip-up.local ] && /etc/ppp/ip-up.local "$@"
diff --git a/rc.d/init.d/functions b/rc.d/init.d/functions
index 9545ff32..2e7475e9 100755
--- a/rc.d/init.d/functions
+++ b/rc.d/init.d/functions
@@ -18,7 +18,7 @@ TEXTDOMAINDIR=/etc/locale
# Make sure umask is sane
umask 022
-# First set up a default search path.
+# Set up a default search path.
PATH="/sbin:/usr/sbin:/bin:/usr/bin:/usr/X11R6/bin"
export PATH
diff --git a/sysconfig/network-scripts/ifdown-ipv6 b/sysconfig/network-scripts/ifdown-ipv6
index 41026b5b..f40d6b21 100755
--- a/sysconfig/network-scripts/ifdown-ipv6
+++ b/sysconfig/network-scripts/ifdown-ipv6
@@ -55,9 +55,7 @@ REALDEVICE=`echo ${DEVICE} | sed 's/:.*//g'`
# Test whether IPv6 should be configured, else stop
[ "${NETWORKING_IPV6}" = "yes" ] || exit 0
-if [ ! -f /etc/sysconfig/network-scripts/network-functions-ipv6 ]; then
- exit 1
-fi
+[ -f /etc/sysconfig/network-scripts/network-functions-ipv6 ] || exit 1
# Source IPv6 helper functions
. /etc/sysconfig/network-scripts/network-functions-ipv6
diff --git a/sysconfig/network-scripts/ifdown-post b/sysconfig/network-scripts/ifdown-post
index 04d516d5..66ea3bdf 100755
--- a/sysconfig/network-scripts/ifdown-post
+++ b/sysconfig/network-scripts/ifdown-post
@@ -2,8 +2,6 @@
# This should be called whenever an interface goes down, not just when
# it is brought down explicitly.
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/ifdown-ppp b/sysconfig/network-scripts/ifdown-ppp
index 1f384e19..4d8cfb75 100755
--- a/sysconfig/network-scripts/ifdown-ppp
+++ b/sysconfig/network-scripts/ifdown-ppp
@@ -1,7 +1,5 @@
#! /bin/bash
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/ifdown-sl b/sysconfig/network-scripts/ifdown-sl
index c4d06b56..11d9e99d 100755
--- a/sysconfig/network-scripts/ifdown-sl
+++ b/sysconfig/network-scripts/ifdown-sl
@@ -1,7 +1,5 @@
#!/bin/bash
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/ifup-ctc b/sysconfig/network-scripts/ifup-ctc
index 0653c7b4..09a64637 100755
--- a/sysconfig/network-scripts/ifup-ctc
+++ b/sysconfig/network-scripts/ifup-ctc
@@ -10,8 +10,6 @@
# alias ctc0 ctc
#
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/ifup-escon b/sysconfig/network-scripts/ifup-escon
index 27d906d1..8cd1d83e 100644
--- a/sysconfig/network-scripts/ifup-escon
+++ b/sysconfig/network-scripts/ifup-escon
@@ -11,8 +11,6 @@
# alias escon0 ctc
#
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/ifup-iucv b/sysconfig/network-scripts/ifup-iucv
index a1059c6f..e257d28a 100755
--- a/sysconfig/network-scripts/ifup-iucv
+++ b/sysconfig/network-scripts/ifup-iucv
@@ -10,8 +10,6 @@
# alias iucv0 netiucv
#
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/ifup-plip b/sysconfig/network-scripts/ifup-plip
index 3c9ffb99..c7c6bb88 100755
--- a/sysconfig/network-scripts/ifup-plip
+++ b/sysconfig/network-scripts/ifup-plip
@@ -1,7 +1,5 @@
#!/bin/sh
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/ifup-plusb b/sysconfig/network-scripts/ifup-plusb
index 84bdaba2..bec39d97 100755
--- a/sysconfig/network-scripts/ifup-plusb
+++ b/sysconfig/network-scripts/ifup-plusb
@@ -11,8 +11,6 @@
# alias plusb0 plusb
#
-PATH=/sbin:/usr/sbin:/bin:/usr/bin
-
cd /etc/sysconfig/network-scripts
. network-functions
diff --git a/sysconfig/network-scripts/network-functions b/sysconfig/network-scripts/network-functions
index 9213cedd..cb56b09f 100644
--- a/sysconfig/network-scripts/network-functions
+++ b/sysconfig/network-scripts/network-functions
@@ -3,6 +3,10 @@
# This file is not a stand-alone shell script; it provides functions
# to network scripts that source it.
+# Set up a default search path.
+PATH="/sbin:/usr/sbin:/bin:/usr/bin:/usr/X11R6/bin"
+export PATH
+
need_config()
{
[ -f "${CONFIG}" ] || \