mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-27 13:27:50 +08:00
don't read all and then throw away the buffer
This commit was moved from ipfs/go-ipfs-http-client@5c96c2954a
This commit is contained in:
parent
4a6d36d98b
commit
7229dbbf73
@ -139,7 +139,7 @@ func (r *Request) Send(c *http.Client) (*Response, error) {
|
||||
nresp.Output = nil
|
||||
|
||||
// drain body and close
|
||||
ioutil.ReadAll(resp.Body)
|
||||
io.Copy(ioutil.Discard, resp.Body)
|
||||
resp.Body.Close()
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user