This repository was archived by the owner on Jul 28, 2020. It is now read-only.

Description
Report from #92
- Receiving
\r\n\r\n at end of second buffer,
it leads to System.Exception: protocol error: more data has been received
first:
HTTP/1.1 200 Connection Established\r\n
second:
content-length: 0\r\n\r\n
Possible fix by #92 suggestion:
index 741cabf..314da50 100644
--- a/Proxy/HttpConnectProxy.cs
+++ b/Proxy/HttpConnectProxy.cs
@@ -171,7 +171,7 @@ namespace SuperSocket.ClientEngine.Proxy
return;
}
- int responseLength = prevMatched > 0 ? (e.Offset - prevMatched) : (e.Offset + result);
+ int responseLength = (prevMatched > 0 && result == e.Offset) ? (e.Offset - prevMatched) : result;
if (e.Offset + e.BytesTransferred > responseLength + m_LineSeparator.Length)
{
PR and test will be pushed soon!