mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-12 10:34:21 +00:00
Fix errors
This commit is contained in:
parent
4012f9ef8b
commit
2881b3cf30
@ -82,6 +82,8 @@ CheckResults FileChecker::check() const
|
||||
|
||||
void FileChecker::repair()
|
||||
{
|
||||
initialize();
|
||||
|
||||
for (const auto & name_size : map)
|
||||
{
|
||||
const String & name = name_size.first;
|
||||
|
@ -95,7 +95,7 @@ private:
|
||||
struct Stream
|
||||
{
|
||||
Stream(const DiskPtr & disk, const String & data_path, size_t max_read_buffer_size_, size_t file_size)
|
||||
: plain(disk->readFile(data_path, std::min(max_read_buffer_size_, file_size))),
|
||||
: plain(file_size ? disk->readFile(data_path, std::min(max_read_buffer_size_, file_size)) : std::make_unique<ReadBuffer>(nullptr, 0)),
|
||||
limited(std::make_unique<LimitReadBuffer>(*plain, file_size, false)),
|
||||
compressed(*limited)
|
||||
{
|
||||
@ -132,10 +132,6 @@ Chunk TinyLogSource::generate()
|
||||
return {};
|
||||
}
|
||||
|
||||
/// if there are no files in the folder, it means that the table is empty
|
||||
if (storage.disk->isDirectoryEmpty(storage.table_path))
|
||||
return {};
|
||||
|
||||
for (const auto & name_type : columns)
|
||||
{
|
||||
MutableColumnPtr column = name_type.type->createColumn();
|
||||
|
Loading…
Reference in New Issue
Block a user