close response body in heartbeat (#1637)
This commit is contained in:
parent
2c0c7225f5
commit
5c1c941851
|
@ -43,6 +43,7 @@ func (h *HeartBeatService) StartHeartBeat(ctx context.Context, t *tomb.Tomb) {
|
||||||
log.Errorf("heartbeat error : %s", err)
|
log.Errorf("heartbeat error : %s", err)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
resp.Response.Body.Close()
|
||||||
if resp.Response.StatusCode != http.StatusOK {
|
if resp.Response.StatusCode != http.StatusOK {
|
||||||
log.Errorf("heartbeat unexpected return code : %d", resp.Response.StatusCode)
|
log.Errorf("heartbeat unexpected return code : %d", resp.Response.StatusCode)
|
||||||
continue
|
continue
|
||||||
|
|
Loading…
Reference in a new issue