mirror of
https://github.com/clearlinux/docker.git
synced 2026-09-04 04:31:28 +00:00
bug fix: close http response body no longer in use
Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
(cherry picked from commit 6c49576a86)
This commit is contained in:
committed by
Jessica Frazelle
parent
d77d7a0056
commit
eb3ed436a4
@@ -68,6 +68,7 @@ func (c *Client) callWithRetry(serviceMethod string, args interface{}, ret inter
|
||||
continue
|
||||
}
|
||||
|
||||
defer resp.Body.Close()
|
||||
if resp.StatusCode != http.StatusOK {
|
||||
remoteErr, err := ioutil.ReadAll(resp.Body)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user