Check for existence of wildcard blocking list before trying to acces it

This commit is contained in:
DL6ER 2017-03-06 16:44:56 +01:00
parent a97f0b1298
commit dce3e50a00
No known key found for this signature in database
GPG Key ID: 00135ACBD90B28DD
1 changed files with 13 additions and 11 deletions

2
pihole
View File

@ -128,6 +128,7 @@ queryFunc() {
done
# Scan for possible wildcard matches
if [ -e "${wildcardlist}" ]; then
local wildcards=($(processWildcards "${domain}"))
for domain in ${wildcards[@]}; do
result=$(scanList "\/${domain}\/" ${wildcardlist})
@ -139,6 +140,7 @@ queryFunc() {
echo ""
fi
done
fi
exit 0
}