Pull request: dnsforward: fix infinite loop
Merge in DNS/adguard-home from 2619-infinite-loop to master Updates #2619. Squashed commit of the following: commit 425fde3f476349571036b9b95c9d0a33703270ee Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Tue Feb 2 13:08:52 2021 +0300 dnsforward: fix infinite loop
This commit is contained in:
parent
39f6689b39
commit
f5c47b6193
|
@ -212,7 +212,7 @@ func (s *Server) Prepare(config *ServerConfig) error {
|
||||||
// Log and go on.
|
// Log and go on.
|
||||||
//
|
//
|
||||||
// TODO(a.garipov): The Snap problem can probably be solved if
|
// TODO(a.garipov): The Snap problem can probably be solved if
|
||||||
// we add the netlink-coinnector interface plug.
|
// we add the netlink-connector interface plug.
|
||||||
log.Error("cannot initialize ipset: %s", err)
|
log.Error("cannot initialize ipset: %s", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -242,6 +242,9 @@ func (c *ipsetCtx) lookupHost(host string) (sets []ipsetProps) {
|
||||||
}
|
}
|
||||||
|
|
||||||
i = strings.Index(host, ".")
|
i = strings.Index(host, ".")
|
||||||
|
if i == -1 {
|
||||||
|
break
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check the root catch-all one.
|
// Check the root catch-all one.
|
||||||
|
|
Loading…
Reference in New Issue