From 4d1f2ce7ad84ec21c26cd409f807e386a29084f2 Mon Sep 17 00:00:00 2001 From: Armon Dadgar Date: Fri, 24 Jan 2014 14:20:55 -0800 Subject: [PATCH] Always send an address in the reply, set to zero --- request.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/request.go b/request.go index 3e92f19..3b0f0da 100644 --- a/request.go +++ b/request.go @@ -260,8 +260,9 @@ func sendReply(w io.Writer, resp uint8, addr *AddrSpec) error { var addrPort uint16 switch { case addr == nil: - addrType = 0 - addrBody = nil + addrType = ipv4Address + addrBody = []byte{0, 0, 0, 0} + addrPort = 0 case addr.FQDN != "": addrType = fqdnAddress