remove CIDR from IPs

This commit is contained in:
Tommy Huff 2016-10-19 14:49:03 -04:00
parent 67f553a7f2
commit b2134b8fde
2 changed files with 11 additions and 12 deletions

View file

@ -209,12 +209,12 @@ else
exit 1
fi
#remove CIDR from IPs
if [[ -n "${IPv6_address}" ]] ; then
piholeIP=${IPv6_address}
piholeIP=$(echo "${piholeIP}" | cut -f1 -d"/")
else
piholeIP=${IPv4_address}
piholeIP=$(echo "${piholeIP}" | cut -f1 -d"/")
IPv6_address=$(echo "${IPv6_address}" | cut -f1 -d"/")
fi
if [[ -n "${IPv6_address}" ]] ; then
IPv4_address=$(echo "${IPv4_address}" | cut -f1 -d"/")
fi
PopWhitelistFile