fix: typo
This commit is contained in:
parent
7df9c44910
commit
6919626580
|
@ -102,7 +102,7 @@ type DigResponse struct {
|
||||||
var (
|
var (
|
||||||
digRespDnsRecordLineRe = regexp.MustCompile(`^([^;\s]\S*)\s+(\d+)\s+([A-Z]+)\s+([A-Z]+)\s+(.*)$`)
|
digRespDnsRecordLineRe = regexp.MustCompile(`^([^;\s]\S*)\s+(\d+)\s+([A-Z]+)\s+([A-Z]+)\s+(.*)$`)
|
||||||
digRespHeaderLineRe = regexp.MustCompile(`^;;.*HEADER.*status: ([A-Z]+),.*$`)
|
digRespHeaderLineRe = regexp.MustCompile(`^;;.*HEADER.*status: ([A-Z]+),.*$`)
|
||||||
digResqQueryTimeLineRe = regexp.MustCompile(`^;; Query time: (\d+) usec$`)
|
digRespQueryTimeLineRe = regexp.MustCompile(`^;; Query time: (\d+) usec$`)
|
||||||
)
|
)
|
||||||
|
|
||||||
func buildDigResponse(buf []byte) (*DigResponse, error) {
|
func buildDigResponse(buf []byte) (*DigResponse, error) {
|
||||||
|
@ -123,7 +123,7 @@ func buildDigResponse(buf []byte) (*DigResponse, error) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
m := digResqQueryTimeLineRe.FindStringSubmatch(line)
|
m := digRespQueryTimeLineRe.FindStringSubmatch(line)
|
||||||
if len(m) == 2 {
|
if len(m) == 2 {
|
||||||
usec, err := strconv.ParseInt(m[1], 10, 64)
|
usec, err := strconv.ParseInt(m[1], 10, 64)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in New Issue