mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-26 17:41:59 +00:00
fix unique_ptr
This commit is contained in:
parent
9b7f87677d
commit
1aa7bbcbbd
@ -18,7 +18,7 @@ class IFileCachePriority
|
|||||||
public:
|
public:
|
||||||
class IIterator;
|
class IIterator;
|
||||||
using Key = FileCacheKey;
|
using Key = FileCacheKey;
|
||||||
using ReadIterator = std::shared_ptr<const IIterator>;
|
using ReadIterator = std::unique_ptr<const IIterator>;
|
||||||
using WriteIterator = std::shared_ptr<IIterator>;
|
using WriteIterator = std::shared_ptr<IIterator>;
|
||||||
|
|
||||||
struct FileCacheRecord
|
struct FileCacheRecord
|
||||||
|
@ -45,7 +45,7 @@ void LRUFileCachePriority::removeAll(std::lock_guard<std::mutex> &)
|
|||||||
|
|
||||||
IFileCachePriority::ReadIterator LRUFileCachePriority::getLowestPriorityReadIterator(std::lock_guard<std::mutex> &)
|
IFileCachePriority::ReadIterator LRUFileCachePriority::getLowestPriorityReadIterator(std::lock_guard<std::mutex> &)
|
||||||
{
|
{
|
||||||
return std::make_shared<const LRUFileCacheIterator>(this, queue.begin());
|
return std::make_unique<const LRUFileCacheIterator>(this, queue.begin());
|
||||||
}
|
}
|
||||||
|
|
||||||
IFileCachePriority::WriteIterator LRUFileCachePriority::getLowestPriorityWriteIterator(std::lock_guard<std::mutex> &)
|
IFileCachePriority::WriteIterator LRUFileCachePriority::getLowestPriorityWriteIterator(std::lock_guard<std::mutex> &)
|
||||||
|
Loading…
Reference in New Issue
Block a user