mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-25 09:02:00 +00:00
Check that position doesn't go beyond end (#20039)
This commit is contained in:
parent
91ea99129e
commit
0db2aa3c2e
@ -55,6 +55,8 @@ public:
|
||||
*/
|
||||
bool next()
|
||||
{
|
||||
assert(position() <= working_buffer.end());
|
||||
|
||||
bytes += offset();
|
||||
bool res = nextImpl();
|
||||
if (!res)
|
||||
@ -62,6 +64,9 @@ public:
|
||||
|
||||
pos = working_buffer.begin() + nextimpl_working_buffer_offset;
|
||||
nextimpl_working_buffer_offset = 0;
|
||||
|
||||
assert(position() <= working_buffer.end());
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user