mirror of
https://github.com/buger/goreplay.git
synced 2024-04-21 12:32:02 +00:00
clean code with #540
This commit is contained in:
+1
-5
@@ -420,11 +420,7 @@ func (c *HTTPClient) send(data []byte, readBytes int, timeout time.Time) (respon
|
||||
}
|
||||
|
||||
if err != nil && readBytes == 0 {
|
||||
maxRead := 100
|
||||
if readBytes < maxRead {
|
||||
maxRead = readBytes
|
||||
}
|
||||
Debug("[HTTPClient] Response read timeout error", err, c.conn, readBytes, string(c.respBuf[:maxRead]))
|
||||
Debug("[HTTPClient] Response read timeout error", err, c.conn, readBytes, string(c.respBuf[:readBytes]))
|
||||
response = errorPayload(HTTP_TIMEOUT)
|
||||
c.Disconnect()
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user