From 3087c54a155faa2649ab72a92e5a901275d8bffd Mon Sep 17 00:00:00 2001 From: Simon Zolin Date: Tue, 23 Apr 2019 19:26:51 +0300 Subject: [PATCH] - app: don't print filter update error messages on first launch before DNS server is set up --- filter.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/filter.go b/filter.go index e6e43334..1a4671b2 100644 --- a/filter.go +++ b/filter.go @@ -178,6 +178,10 @@ func periodicallyRefreshFilters() { func refreshFiltersIfNecessary(force bool) int { var updateFilters []filter + if config.firstRun { + return 0 + } + config.RLock() for i := range config.Filters { f := &config.Filters[i] // otherwise we will be operating on a copy