mirror of
https://github.com/pocoproject/poco.git
synced 2025-07-03 09:15:21 +02:00
additonal fix for GH #1212: WebSocketImpl::available() now reports number of bytes in internal buffer.
This commit is contained in:
parent
675e7f6242
commit
7f17dfcc83
@ -375,6 +375,10 @@ Poco::Timespan WebSocketImpl::getReceiveTimeout()
|
|||||||
|
|
||||||
int WebSocketImpl::available()
|
int WebSocketImpl::available()
|
||||||
{
|
{
|
||||||
|
int n = _buffer.size() - _bufferOffset;
|
||||||
|
if (n > 0)
|
||||||
|
return n + _pStreamSocketImpl->available();
|
||||||
|
else
|
||||||
return _pStreamSocketImpl->available();
|
return _pStreamSocketImpl->available();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user