mirror of
https://github.com/coredns/coredns.git
synced 2025-10-27 16:24:19 -04:00
lint: enable prealloc (#7493)
This commit is contained in:
@@ -30,7 +30,7 @@ func stripZone(host string) string {
|
||||
// and in case of filename a resolv.conf like file is (assumed) and parsed and
|
||||
// the nameservers found are returned.
|
||||
func HostPortOrFile(s ...string) ([]string, error) {
|
||||
var servers []string
|
||||
var servers []string //nolint:prealloc // impossible to know the final length upfront
|
||||
for _, h := range s {
|
||||
trans, host := Transport(h)
|
||||
if len(host) == 0 {
|
||||
|
||||
Reference in New Issue
Block a user