This commit is contained in:
gun9nir 2024-07-07 19:24:29 -07:00
parent be9a17f2cc
commit e16cb83ca3

View File

@ -366,14 +366,17 @@ Strings StorageFile::getPathsList(const String & table_path, const String & user
}
else if (path.find_first_of("*?{") == std::string::npos)
{
if (!fs::is_directory(path)) {
if (!fs::is_directory(path))
{
std::error_code error;
size_t size = fs::file_size(path, error);
if (!error)
total_bytes_to_read += size;
paths.push_back(path);
} else {
}
else
{
/// We list non-directory files under that directory.
paths = listFilesWithRegexpMatching(path / fs::path("*"), total_bytes_to_read);
can_be_directory = false;