aboutsummaryrefslogtreecommitdiff
path: root/net.Linux/apipa.sh
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2007-11-28 15:45:03 +0000
committerRoy Marples <roy@marples.name>2007-11-28 15:45:03 +0000
commitac9279cc0d5a00bc17908b2914941186020cd3ce (patch)
tree850a4fe19917113e75bfd2e79d00b58208468503 /net.Linux/apipa.sh
parent444f23e2d158389b22d40537fc9b027d9f575229 (diff)
Massive whitespace cleanup
Diffstat (limited to 'net.Linux/apipa.sh')
-rw-r--r--net.Linux/apipa.sh7
1 files changed, 4 insertions, 3 deletions
diff --git a/net.Linux/apipa.sh b/net.Linux/apipa.sh
index d7c959eb..42e85f5d 100644
--- a/net.Linux/apipa.sh
+++ b/net.Linux/apipa.sh
@@ -28,8 +28,9 @@ apipa_depend() {
}
_random() {
- if [ -n "${BASH}" ] ; then
- echo "${RANDOM}"
+ local r=${RANDOM}
+ if [ -n "${r}" ]; then
+ echo "${r}"
else
uuidgen | sed -n -e 's/[^[:digit:]]//g' -e 's/\(^.\{1,7\}\).*/\1/p'
fi
@@ -49,7 +50,7 @@ apipa_start() {
addr="169.254.${i1}.${i2}"
vebegin "${addr}/16"
- if ! arping_address "${addr}" ; then
+ if ! arping_address "${addr}"; then
eval config_${config_index}="\"${addr}/16 broadcast 169.254.255.255\""
config_index=$((${config_index} - 1))
veend 0