Merge pull request #4450 from pi-hole/unblock_NODATA

Unblock adlist domain during gravity run in NODATA mode
This commit is contained in:
DL6ER 2021-12-21 22:08:14 +01:00 committed by GitHub
commit 54c58327f1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -604,6 +604,10 @@ gravity_DownloadBlocklistFromUrl() {
if [[ $(dig "${domain}" | grep "NXDOMAIN" -c) -ge 1 ]]; then if [[ $(dig "${domain}" | grep "NXDOMAIN" -c) -ge 1 ]]; then
blocked=true blocked=true
fi;; fi;;
"NODATA")
if [[ $(dig "${domain}" | grep "NOERROR" -c) -ge 1 ]] && [[ -z $(dig +short "${domain}") ]]; then
blocked=true
fi;;
"NULL"|*) "NULL"|*)
if [[ $(dig "${domain}" +short | grep "0.0.0.0" -c) -ge 1 ]]; then if [[ $(dig "${domain}" +short | grep "0.0.0.0" -c) -ge 1 ]]; then
blocked=true blocked=true