aboutsummaryrefslogtreecommitdiff
path: root/plugin
diff options
context:
space:
mode:
Diffstat (limited to 'plugin')
-rw-r--r--plugin/cache/cache_test.go2
-rw-r--r--plugin/pkg/edns/edns.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/plugin/cache/cache_test.go b/plugin/cache/cache_test.go
index 4afaf73c4..b32353372 100644
--- a/plugin/cache/cache_test.go
+++ b/plugin/cache/cache_test.go
@@ -191,7 +191,7 @@ func TestCache(t *testing.T) {
m := tc.in.Msg()
m = cacheMsg(m, tc)
- state := request.Request{W: nil, Req: m}
+ state := request.Request{W: &test.ResponseWriter{}, Req: m}
mt, _ := response.Typify(m, utc)
valid, k := key(state.Name(), m, mt, state.Do())
diff --git a/plugin/pkg/edns/edns.go b/plugin/pkg/edns/edns.go
index 68fb03865..31f57ea9b 100644
--- a/plugin/pkg/edns/edns.go
+++ b/plugin/pkg/edns/edns.go
@@ -63,7 +63,7 @@ func Version(req *dns.Msg) (*dns.Msg, error) {
}
// Size returns a normalized size based on proto.
-func Size(proto string, size int) int {
+func Size(proto string, size uint16) uint16 {
if proto == "tcp" {
return dns.MaxMsgSize
}