mirror of
https://github.com/buger/goreplay.git
synced 2024-04-21 12:32:02 +00:00
Properly return from errors from ReadRequest
This commit is contained in:
@@ -34,6 +34,10 @@ func ParseRequest(data []byte) (request *http.Request, err error) {
|
||||
|
||||
request, err = http.ReadRequest(reader)
|
||||
|
||||
if (err != nil) {
|
||||
return
|
||||
}
|
||||
|
||||
if request.Method == "POST" {
|
||||
body, _ := ioutil.ReadAll(reader)
|
||||
bodyBuf := bytes.NewBuffer(body)
|
||||
|
||||
Reference in New Issue
Block a user