mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-19 04:42:37 +00:00
fix notchunked mode in ReadBufferFromPocoSocketChunked
This commit is contained in:
parent
94bc0a1e96
commit
147ad42df0
@ -44,6 +44,13 @@ void ReadBufferFromPocoSocketChunked::setAsyncCallback(AsyncCallback async_callb
|
||||
buffer_socket.setAsyncCallback(async_callback_);
|
||||
}
|
||||
|
||||
bool ReadBufferFromPocoSocketChunked::hasBufferedData() const
|
||||
{
|
||||
if (chunked)
|
||||
return hasPendingData() || buffer_socket.hasPendingData();
|
||||
return hasPendingData();
|
||||
}
|
||||
|
||||
bool ReadBufferFromPocoSocketChunked::startChunk()
|
||||
{
|
||||
if (buffer_socket.read(reinterpret_cast<char *>(&chunk_left), sizeof(chunk_left)) < sizeof(chunk_left))
|
||||
|
@ -16,7 +16,7 @@ public:
|
||||
bool poll(size_t timeout_microseconds);
|
||||
void setAsyncCallback(AsyncCallback async_callback_);
|
||||
|
||||
bool hasBufferedData() const { return hasPendingData() || buffer_socket.hasPendingData(); }
|
||||
bool hasBufferedData() const;
|
||||
|
||||
Poco::Net::SocketAddress peerAddress() { return peer_address; }
|
||||
Poco::Net::SocketAddress ourAddress() { return our_address; }
|
||||
|
Loading…
Reference in New Issue
Block a user