diff options
author | 2019-06-07 15:29:42 +0100 | |
---|---|---|
committer | 2019-06-07 15:29:42 +0100 | |
commit | 458e7781135d370704a4f51df24426d158a57adc (patch) | |
tree | f6e93c4b5fad736b010f146028a9ca3ffb4aac46 /plugin | |
parent | a657e1f6618ee94c46fa9374dd29c21345710d38 (diff) | |
download | coredns-458e7781135d370704a4f51df24426d158a57adc.tar.gz coredns-458e7781135d370704a4f51df24426d158a57adc.tar.zst coredns-458e7781135d370704a4f51df24426d158a57adc.zip |
Revert "be sure to close connection after completion of xfr out. (#2866)" (#2872)
This reverts commit a657e1f6618ee94c46fa9374dd29c21345710d38.
Diffstat (limited to 'plugin')
-rw-r--r-- | plugin/file/xfr.go | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/plugin/file/xfr.go b/plugin/file/xfr.go index 6be265b34..18b6bb117 100644 --- a/plugin/file/xfr.go +++ b/plugin/file/xfr.go @@ -33,10 +33,7 @@ func (x Xfr) ServeDNS(ctx context.Context, w dns.ResponseWriter, r *dns.Msg) (in ch := make(chan *dns.Envelope) defer close(ch) tr := new(dns.Transfer) - go func() { - tr.Out(w, r, ch) - w.Close() - }() + go tr.Out(w, r, ch) j, l := 0, 0 records = append(records, records[0]) // add closing SOA to the end @@ -54,6 +51,7 @@ func (x Xfr) ServeDNS(ctx context.Context, w dns.ResponseWriter, r *dns.Msg) (in } w.Hijack() + // w.Close() // Client closes connection return dns.RcodeSuccess, nil } |