From 7f0c7d78029026a56c45bafc398e3a46cb2dbad9 Mon Sep 17 00:00:00 2001 From: Dreamacro <305009791@qq.com> Date: Sun, 3 Mar 2019 17:23:59 +0800 Subject: [PATCH] Fix: should not return extra ip in msgToIP --- dns/client.go | 9 --------- 1 file changed, 9 deletions(-) diff --git a/dns/client.go b/dns/client.go index 634722fc..1d68dc70 100644 --- a/dns/client.go +++ b/dns/client.go @@ -184,15 +184,6 @@ func (r *Resolver) msgToIP(msg *D.Msg) []net.IP { } } - for _, extra := range msg.Extra { - switch record := extra.(type) { - case *D.AAAA: - ips = append(ips, record.AAAA) - case *D.A: - ips = append(ips, record.A) - } - } - return ips }