Skip to content

Commit

Permalink
Fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
Algunenano committed Mar 5, 2024
1 parent 38afa46 commit f02e529
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Storages/StorageFile.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -353,12 +353,12 @@ std::unique_ptr<ReadBuffer> selectReadBuffer(
else if (read_method == LocalFSReadMethod::io_uring && !use_table_fd)
{
#if USE_LIBURING
auto & reader = context->getIOURingReader();
if (!reader.isSupported())
static std::shared_ptr<IOUringReader> reader = std::make_shared<IOUringReader>(512);
if (!reader->isSupported())
throw Exception(ErrorCodes::UNSUPPORTED_METHOD, "io_uring is not supported by this system");

res = std::make_unique<AsynchronousReadBufferFromFileWithDescriptorsCache>(
reader,
*reader,
Priority{},
current_path,
context->getSettingsRef().max_read_buffer_size);
Expand Down

0 comments on commit f02e529

Please sign in to comment.