Skip to content

Commit 74d2ba1

Browse files
authored
MsgInvalidFunc: Make DefaultMsgInvalidFunc a variable. (#1690)
For parity with DefaultMsgAcceptFunc that is a variable. Signed-off-by: Ilya Kulakov <kulakov.ilya@gmail.com>
1 parent b39ef96 commit 74d2ba1

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

server.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,9 @@ type DecorateWriter func(Writer) Writer
194194
// rejected (or ignored) by the MsgAcceptFunc, or passed to this function.
195195
type MsgInvalidFunc func(m []byte, err error)
196196

197-
func DefaultMsgInvalidFunc(m []byte, err error) {}
197+
var DefaultMsgInvalidFunc MsgInvalidFunc = defaultMsgInvalidFunc
198+
199+
func defaultMsgInvalidFunc(m []byte, err error) {}
198200

199201
// A Server defines parameters for running an DNS server.
200202
type Server struct {

0 commit comments

Comments
 (0)