aboutsummaryrefslogtreecommitdiffstats
path: root/sysconfig/network-scripts/network-functions
diff options
context:
space:
mode:
authorLukas Nykryn <lnykryn@redhat.com>2015-01-12 12:49:46 +0100
committerLukas Nykryn <lnykryn@redhat.com>2015-01-12 12:50:01 +0100
commit1f230a3d2e2733e30577c91645005801ab2c0f40 (patch)
treee42d6c22fb8d6a42036fc83211cb6b3dd574edda /sysconfig/network-scripts/network-functions
parent3d1f30095582f84206826f7ede970c45e5a6b5ba (diff)
downloadinitscripts-1f230a3d2e2733e30577c91645005801ab2c0f40.tar
initscripts-1f230a3d2e2733e30577c91645005801ab2c0f40.tar.gz
initscripts-1f230a3d2e2733e30577c91645005801ab2c0f40.tar.bz2
initscripts-1f230a3d2e2733e30577c91645005801ab2c0f40.tar.xz
initscripts-1f230a3d2e2733e30577c91645005801ab2c0f40.zip
network-functions: is_available_wait should wait even in the case that is_available returns 2
Diffstat (limited to 'sysconfig/network-scripts/network-functions')
-rw-r--r--sysconfig/network-scripts/network-functions6
1 files changed, 2 insertions, 4 deletions
diff --git a/sysconfig/network-scripts/network-functions b/sysconfig/network-scripts/network-functions
index 1ecbcfcb..9a5e359c 100644
--- a/sysconfig/network-scripts/network-functions
+++ b/sysconfig/network-scripts/network-functions
@@ -336,18 +336,16 @@ is_available_wait ()
local retry=${2##*[!0-9]*}
- is_available $1
+ is_available $1 && return 0
ret=$?
- [ 0"$ret" -ne 1 ] && return $ret
-
while [ 0"$retry" -gt 0 ]; do
sleep 1
[ -d "/sys/class/net/$1" ] && return 0
retry=$(($retry -1))
done
- return 1
+ return $ret
}
need_hostname ()