From c572c7b0e93f9e96cd65b7ec406a00b806735492 Mon Sep 17 00:00:00 2001 From: Eugene Bujak Date: Fri, 7 Sep 2018 15:46:38 +0300 Subject: [PATCH] dnsfilter metrics -- parental cache hits were counted as safebrowsing cache hits --- dnsfilter/dnsfilter.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dnsfilter/dnsfilter.go b/dnsfilter/dnsfilter.go index 0bf004ce..59d731b6 100644 --- a/dnsfilter/dnsfilter.go +++ b/dnsfilter/dnsfilter.go @@ -563,7 +563,7 @@ func (d *Dnsfilter) lookupCommon(host string, lookupstats *LookupStats, cache gc // check cache cachedValue, isFound, err := getCachedReason(cache, host) if isFound { - atomic.AddUint64(&stats.Safebrowsing.CacheHits, 1) + atomic.AddUint64(&lookupstats.CacheHits, 1) return cachedValue, nil } if err != nil {