diff --git a/app/dns/udpns.go b/app/dns/udpns.go index ca4a1ed1..5cc89e66 100644 --- a/app/dns/udpns.go +++ b/app/dns/udpns.go @@ -256,6 +256,7 @@ func msgToBuffer(msg *dns.Msg) (*buf.Buffer, error) { writtenBuffer, err := msg.PackBuffer(b) return len(writtenBuffer), err }); err != nil { + buffer.Release() return nil, err } return buffer, nil