mirror of
https://github.com/soypat/lneto.git
synced 2026-08-20 22:49:11 +00:00
mdns: avoid dropping large answers that could not be decoded completely
This commit is contained in:
+2
-2
@@ -174,8 +174,8 @@ func (c *Client) Demux(carrierData []byte, frameOffset int) error {
|
||||
// Incoming query — match against our services.
|
||||
var query dns.Message
|
||||
query.LimitResourceDecoding(f.QDCount(), 0, 0, 0)
|
||||
_, _, err = query.Decode(frame)
|
||||
if err != nil {
|
||||
_, incomplete, err := query.Decode(frame)
|
||||
if err != nil && !incomplete {
|
||||
return err
|
||||
}
|
||||
for i := range query.Questions {
|
||||
|
||||
Reference in New Issue
Block a user