Much better message length
This commit is contained in:
parent
f1a3b31384
commit
416eb764c7
4
msg.go
4
msg.go
|
@ -1020,8 +1020,8 @@ func (dns *Msg) Pack() (msg []byte, ok bool) {
|
||||||
dh.Nscount = uint16(len(ns))
|
dh.Nscount = uint16(len(ns))
|
||||||
dh.Arcount = uint16(len(extra))
|
dh.Arcount = uint16(len(extra))
|
||||||
|
|
||||||
// TODO: still too much, but better than 64K
|
// TODO: still a little too much, but better than 64K...
|
||||||
msg = make([]byte, dns.Len()*4)
|
msg = make([]byte, dns.Len())
|
||||||
|
|
||||||
// Pack it in: header and then the pieces.
|
// Pack it in: header and then the pieces.
|
||||||
off := 0
|
off := 0
|
||||||
|
|
Loading…
Reference in New Issue