mirror of
https://github.com/miekg/dns.git
synced 2025-10-12 02:11:13 +02:00
gofmt
This commit is contained in:
parent
2a69247960
commit
7e2d4ac1d4
@ -58,8 +58,8 @@ func addresses(conf *dns.ClientConfig, c *dns.Client, name string) []string {
|
||||
m4.SetQuestion(dns.Fqdn(os.Args[1]), dns.TypeA)
|
||||
m6 := new(dns.Msg)
|
||||
m6.SetQuestion(dns.Fqdn(os.Args[1]), dns.TypeAAAA)
|
||||
c.Do(m4, conf.Servers[0] + ":" + conf.Port)
|
||||
c.Do(m6, conf.Servers[0] + ":" + conf.Port)
|
||||
c.Do(m4, conf.Servers[0]+":"+conf.Port)
|
||||
c.Do(m6, conf.Servers[0]+":"+conf.Port)
|
||||
|
||||
var ips []string
|
||||
i := 2 // two outstanding queries
|
||||
|
@ -214,7 +214,6 @@ func toFingerprint(m *dns.Msg) *fingerprint {
|
||||
f.Query.Qclass = 0
|
||||
}
|
||||
|
||||
|
||||
f.Opcode = h.Opcode
|
||||
f.Rcode = h.Rcode
|
||||
f.Response = h.Response
|
||||
|
@ -76,7 +76,7 @@ func main() {
|
||||
listen := flag.String("listen", "127.0.0.1:8053", "set the listener address")
|
||||
server := flag.String("server", "127.0.0.1:53", "remote server address(es), seperate with commas")
|
||||
verbose = flag.Bool("verbose", false, "Print packet as it flows through")
|
||||
// cpuprofile := flag.String("cpuprofile", "", "write cpu profile to file")
|
||||
// cpuprofile := flag.String("cpuprofile", "", "write cpu profile to file")
|
||||
flag.Usage = func() {
|
||||
flag.PrintDefaults()
|
||||
}
|
||||
|
@ -21,7 +21,7 @@ func main() {
|
||||
m.SetEdns0(2048, true)
|
||||
|
||||
c := dns.NewClient()
|
||||
r, _ := c.Exchange(m, conf.Servers[0] + ":" + conf.Port)
|
||||
r, _ := c.Exchange(m, conf.Servers[0]+":"+conf.Port)
|
||||
if r == nil {
|
||||
fmt.Printf("*** no answer received for %s\n", os.Args[1])
|
||||
os.Exit(1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user