Skip to content

Commit c18b824

Browse files
committed
vsp: be sure to close http response body
1 parent d6e1231 commit c18b824

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

internal/vsp/client.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,8 @@ func (c *client) do(ctx context.Context, method, path string, addr dcrutil.Addre
7070
if err != nil {
7171
return fmt.Errorf("%s %s: %w", method, httpReq.URL.String(), err)
7272
}
73+
defer reply.Body.Close()
74+
7375
status := reply.StatusCode
7476
is200 := status == 200
7577
is4xx := status >= 400 && status <= 499

0 commit comments

Comments
 (0)