[Modify] Polish it
This commit is contained in:
parent
f1525f2b4c
commit
9e794d890f
@ -519,24 +519,17 @@ namespace WebSocketSharp.Net
|
||||
|
||||
var buff = _requestBuffer.GetBuffer ();
|
||||
var len = (int) _requestBuffer.Length;
|
||||
var cnt = len - _position;
|
||||
disposeRequestBuffer ();
|
||||
|
||||
if (chunked) {
|
||||
_inputStream = new ChunkedRequestStream (
|
||||
_stream, buff, _position, len - _position, _context
|
||||
_inputStream = chunked
|
||||
? new ChunkedRequestStream (
|
||||
_stream, buff, _position, cnt, _context
|
||||
)
|
||||
: new RequestStream (
|
||||
_stream, buff, _position, cnt, contentLength
|
||||
);
|
||||
|
||||
return _inputStream;
|
||||
}
|
||||
|
||||
_inputStream = new RequestStream (
|
||||
_stream,
|
||||
buff,
|
||||
_position,
|
||||
len - _position,
|
||||
contentLength
|
||||
);
|
||||
|
||||
return _inputStream;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user