From 16d732698d49a5c18414ca8bcdee974869de451d Mon Sep 17 00:00:00 2001 From: Emanuele Danovaro Date: Wed, 17 Apr 2024 16:18:57 +0100 Subject: [PATCH] addressed PR comments --- src/eckit/io/PooledFile.cc | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/eckit/io/PooledFile.cc b/src/eckit/io/PooledFile.cc index 949babad8..441a9e7d2 100644 --- a/src/eckit/io/PooledFile.cc +++ b/src/eckit/io/PooledFile.cc @@ -8,17 +8,21 @@ * does it submit to any jurisdiction. */ +#include "eckit/io/PooledFile.h" + #include +#include #include +#include #include -#include +#include +#include #include "eckit/config/LibEcKit.h" #include "eckit/config/Resource.h" #include "eckit/exception/Exceptions.h" #include "eckit/filesystem/PathName.h" #include "eckit/io/Buffer.h" -#include "eckit/io/PooledFile.h" #include "eckit/log/Bytes.h" namespace eckit { @@ -282,7 +286,7 @@ eckit::PoolFileEntry* Pool::get(const eckit::PathName& name) { std::lock_guard lock(filePoolMutex_); auto j = filePool_.find(name); if (j == filePool_.end()) { - filePool_.emplace(std::make_pair(name, std::unique_ptr(new eckit::PoolFileEntry(name)))); + filePool_.emplace(name, new eckit::PoolFileEntry(name)); j = filePool_.find(name); } return (*j).second.get();