diff options
| author | Martin Ridgers <[email protected]> | 2024-09-12 14:01:48 +0200 |
|---|---|---|
| committer | Martin Ridgers <[email protected]> | 2024-09-19 15:26:13 +0200 |
| commit | af2a41282c9ecb8fc8a54557079ab4bcb957b350 (patch) | |
| tree | e80ee9a6289496a699f3405cb79a8e3de3919259 /src | |
| parent | Updated changelog (diff) | |
| download | zen-af2a41282c9ecb8fc8a54557079ab4bcb957b350.tar.xz zen-af2a41282c9ecb8fc8a54557079ab4bcb957b350.zip | |
Placate clang
Diffstat (limited to 'src')
| -rw-r--r-- | src/zenserver/projectstore/projectstore.cpp | 8 | ||||
| -rw-r--r-- | src/zenserver/projectstore/projectstore.h | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/zenserver/projectstore/projectstore.cpp b/src/zenserver/projectstore/projectstore.cpp index d47b4e50b..b58f490e2 100644 --- a/src/zenserver/projectstore/projectstore.cpp +++ b/src/zenserver/projectstore/projectstore.cpp @@ -2032,14 +2032,14 @@ ProjectStore::Oplog::IterateFileMap( } void -ProjectStore::Oplog::IterateOplog(std::function<void(CbObjectView)>&& Handler, const Paging& EntryPaging) +ProjectStore::Oplog::IterateOplog(std::function<void(CbObjectView)>&& Handler, const Paging* EntryPaging) { RwLock::SharedLockScope _(m_OplogLock); IterateOplogLocked(std::move(Handler), EntryPaging); } void -ProjectStore::Oplog::IterateOplogLocked(std::function<void(CbObjectView)>&& Handler, const Paging& EntryPaging) +ProjectStore::Oplog::IterateOplogLocked(std::function<void(CbObjectView)>&& Handler, const Paging* EntryPaging) { ZEN_TRACE_CPU("Store::Oplog::IterateOplogLocked"); if (!m_Storage) @@ -2063,9 +2063,9 @@ ProjectStore::Oplog::IterateOplogLocked(std::function<void(CbObjectView)>&& Hand }); std::span<OplogEntryAddress> EntrySpan; - if (EntryPaging.Start >= 0 || EntryPaging.Count >= 0) + if (EntryPaging != nullptr) { - int32_t Indices[2] = {EntryPaging.Start, EntryPaging.Start + EntryPaging.Count}; + int32_t Indices[2] = {EntryPaging->Start, EntryPaging->Start + EntryPaging->Count}; for (int32_t& Index : Indices) { Index = std::max<int32_t>(0, Index); diff --git a/src/zenserver/projectstore/projectstore.h b/src/zenserver/projectstore/projectstore.h index c001293a9..10008f989 100644 --- a/src/zenserver/projectstore/projectstore.h +++ b/src/zenserver/projectstore/projectstore.h @@ -104,9 +104,9 @@ public: std::vector<ChunkInfo> GetAllChunksInfo(); void IterateChunkMap(std::function<void(const Oid&, const IoHash& Hash)>&& Fn); void IterateFileMap(std::function<void(const Oid&, const std::string_view& ServerPath, const std::string_view& ClientPath)>&& Fn); - void IterateOplog(std::function<void(CbObjectView)>&& Fn, const Paging& EntryPaging = {}); + void IterateOplog(std::function<void(CbObjectView)>&& Fn, const Paging* EntryPaging = nullptr); void IterateOplogWithKey(std::function<void(uint32_t, const Oid&, CbObjectView)>&& Fn); - void IterateOplogLocked(std::function<void(CbObjectView)>&& Fn, const Paging& EntryPaging = {}); + void IterateOplogLocked(std::function<void(CbObjectView)>&& Fn, const Paging* EntryPaging = nullptr); size_t GetOplogEntryCount() const; std::optional<CbObject> GetOpByKey(const Oid& Key); |