Skip to content

Commit

Permalink
Silence logging on malformed responses
Browse files Browse the repository at this point in the history
  • Loading branch information
tmm1 committed Nov 6, 2018
1 parent 656e61d commit 018c00d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion httpu/httpu.go
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,9 @@ func (httpu *HTTPUClient) Do(req *http.Request, timeout time.Duration, numSends
// Parse response.
response, err := http.ReadResponse(bufio.NewReader(bytes.NewBuffer(responseBytes[:n])), req)
if err != nil {
log.Printf("httpu: error while parsing response: %v", err)
if err != io.ErrUnexpectedEOF {
log.Printf("httpu: error while parsing response: %v", err)
}
continue
}

Expand Down

0 comments on commit 018c00d

Please sign in to comment.