Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Leonid Bugaev
2018-08-10 21:35:19 +05:00
+5
View File
@@ -16,6 +16,11 @@ func prettifyHTTP(p []byte) []byte {
body := p[headSize:]
headersPos := proto.MIMEHeadersEndPos(body)
if headersPos < 5 || headersPos > len(body) {
return p
}
headers := body[:headersPos]
content := body[headersPos:]