From 397b0ccdf7ae670ec67ba5bd3f0790f82a3a1213 Mon Sep 17 00:00:00 2001 From: Ainar Garipov Date: Mon, 17 May 2021 17:48:35 +0300 Subject: [PATCH] Pull request: querylog: imp time cmp Merge in DNS/adguard-home from imp-time-cmp to master Squashed commit of the following: commit d1e933b2b83dd8b5ffcd4a35e85270e722e5b3fd Author: Ainar Garipov Date: Mon May 17 17:41:54 2021 +0300 querylog: imp time cmp --- internal/querylog/searchparams.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/querylog/searchparams.go b/internal/querylog/searchparams.go index 193956e6..eee9ec7a 100644 --- a/internal/querylog/searchparams.go +++ b/internal/querylog/searchparams.go @@ -45,7 +45,7 @@ func (s *searchParams) quickMatch(line string, findClient quickMatchClientFunc) // match - checks if the logEntry matches the searchParams func (s *searchParams) match(entry *logEntry) bool { - if !s.olderThan.IsZero() && entry.Time.UnixNano() >= s.olderThan.UnixNano() { + if !s.olderThan.IsZero() && !entry.Time.Before(s.olderThan) { // Ignore entries newer than what was requested return false }