ameshkov / dnslookup

Simple command line utility to make DNS lookups to the specified server
MIT License
816 stars 72 forks source link

Check arguments length before reading #72

Closed Howard20181 closed 2 months ago

Howard20181 commented 2 months ago

fix

panic: runtime error: index out of range [1] with length 1

goroutine 1 [running]:
main.getQuestion()
        /build/dnslookup/parts/dnslookup/build/main.go:239 +0x147
main.main()
        /build/dnslookup/parts/dnslookup/build/main.go:44 +0x145