Fix some more, #180888.

This commit is contained in:
Roy Marples 2007-11-01 15:53:52 +00:00
parent c3690f2d1b
commit 02f47103e3

View File

@ -24,10 +24,13 @@ arping_address() {
[ -z "${w}" ] && w=${arping_wait:-5}
if type arping2 >/dev/null 2>&1; then
[ -z "$(_get_inet_address)" ] && opts="${opts} -0"
[ -n "${spoof}" ] && opts="${opts} -S ${spoof}"
if [ -n "${spoof}" ]; then
opts="${opts} -S ${spoof}"
else
[ -z "$(_get_inet_address)" ] && opts="${opts} -0"
fi
while [ ${w} -gt 0 -a -z "${foundmac}" ]; do
foundmac="$(arping2 ${opts} -r -c 1 -0 -i "${IFACE}" "${ip}" 2>/dev/null | \
foundmac="$(arping2 ${opts} -r -c 1 -i "${IFACE}" "${ip}" 2>/dev/null | \
sed -e 'y/abcdef/ABCDEF/')"
w=$((${w} - 1))
done