Commit 9230e177 authored by Miek Gieben's avatar Miek Gieben Committed by GitHub

pkg/upstream: set edns0 and Do when required (#4055)

Set these options of the requests warrents them.
Signed-off-by: default avatarMiek Gieben <miek@miek.nl>
parent 1efd7e36
...@@ -25,8 +25,11 @@ func (u *Upstream) Lookup(ctx context.Context, state request.Request, name strin ...@@ -25,8 +25,11 @@ func (u *Upstream) Lookup(ctx context.Context, state request.Request, name strin
return nil, fmt.Errorf("no full server is running") return nil, fmt.Errorf("no full server is running")
} }
size := state.Size()
do := state.Do()
req := new(dns.Msg) req := new(dns.Msg)
req.SetQuestion(name, typ) req.SetQuestion(name, typ)
req.SetEdns0(uint16(size), do)
nw := nonwriter.New(state.W) nw := nonwriter.New(state.W)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment