Skip if it's an IPv6 address; at some point, maybe we'll support that too.

This commit is contained in:
Timothy Allen 2018-03-09 20:30:01 +02:00
parent 1214a6532e
commit 848d673257

View File

@ -17,6 +17,11 @@ if [ -f "${HOME}/${cache}" ]; then
old_ip=$(cat "${HOME}/${cache}") old_ip=$(cat "${HOME}/${cache}")
fi fi
# Exit if we're at an IPv6 address
if [ -z "${ip##*:*}" ]; then
exit;
fi
if [ "${set_ip}" = "${ip}" ] && [ "${ip}" = "${old_ip}" ]; then if [ "${set_ip}" = "${ip}" ] && [ "${ip}" = "${old_ip}" ]; then
exit; exit;
else else