Skip to content

Commit

Permalink
remote: close response body during watch()
Browse files Browse the repository at this point in the history
  • Loading branch information
jonboulle authored and Eugene Yakubovich committed Oct 19, 2015
1 parent 307be5f commit 86a0771
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions remote/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,7 @@ func (m *RemoteManager) WatchLeases(ctx context.Context, network string, cursor
if err != nil {
return subnet.WatchResult{}, err
}
defer resp.Body.Close()

if resp.StatusCode != http.StatusOK {
return subnet.WatchResult{}, httpError(resp)
Expand Down

0 comments on commit 86a0771

Please sign in to comment.