mirror of https://github.com/tidwall/tile38.git
support all versions of HTTP, fixes #38
This commit is contained in:
parent
7b8c2dae85
commit
01c05b2ce9
|
@ -139,7 +139,7 @@ func (ar *AnyReaderWriter) ReadMessage() (*Message, error) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
if strings.HasSuffix(line, " HTTP/1.1") {
|
if len(line) > 9 && line[len(line)-9:len(line)-3] == " HTTP/" {
|
||||||
return ar.readHTTPMessage()
|
return ar.readHTTPMessage()
|
||||||
}
|
}
|
||||||
case '$':
|
case '$':
|
||||||
|
|
Loading…
Reference in New Issue