diff options
| author | Mason Reed <mason@vector35.com> | 2025-04-26 15:23:56 -0400 |
|---|---|---|
| committer | Mason Reed <mason@vector35.com> | 2025-04-26 15:23:56 -0400 |
| commit | b8cf3ecf998ece0275757999c788ec1912ea7977 (patch) | |
| tree | cae092abf512298cfb4f9bbd9787a3c030e41027 /view/sharedcache/core/SharedCacheController.cpp | |
| parent | 9262278979709181414664053523657355762707 (diff) | |
[SharedCache] Update the ref count warning to only show when above 2
We will have 2 live references in the DeleteController function, this warning does not need to be shown.
Diffstat (limited to 'view/sharedcache/core/SharedCacheController.cpp')
| -rw-r--r-- | view/sharedcache/core/SharedCacheController.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/view/sharedcache/core/SharedCacheController.cpp b/view/sharedcache/core/SharedCacheController.cpp index 6e275b4b..41118d7a 100644 --- a/view/sharedcache/core/SharedCacheController.cpp +++ b/view/sharedcache/core/SharedCacheController.cpp @@ -33,7 +33,8 @@ void DeleteController(const FileMetadata& file) { auto controller = it->second; // Someone is still holding the controller, lets warn about this. - if (controller->m_refs > 1) + // 2 is expected here because we have one held in `controllers` and one held by `controller`. + if (controller->m_refs > 2) LogWarn("Deleting SharedCacheController for view %llx, but there are still %d references", id, controller->m_refs.load()); |
