@@ -1996,7 +1996,7 @@ std::vector<std::string> CacheAllocator<CacheTrait>::dumpEvictionIterator(
19961996 }
19971997
19981998 // Always evict from the lowest layer.
1999- auto tid = numTiers - 1 ;
1999+ int tid = numTiers - 1 ;
20002000
20012001 if (static_cast <size_t >(tid) >= mmContainers_.size () ||
20022002 static_cast <size_t >(pid) >= mmContainers_[tid].size () ||
@@ -2008,7 +2008,7 @@ std::vector<std::string> CacheAllocator<CacheTrait>::dumpEvictionIterator(
20082008 std::vector<std::string> content;
20092009
20102010 size_t i = 0 ;
2011- while (i < numItems) {
2011+ while (i < numItems && tid >= 0 ) {
20122012 auto & mm = *mmContainers_[tid][pid][cid];
20132013 auto evictItr = mm.getEvictionIterator ();
20142014 while (evictItr && i < numItems) {
@@ -3668,7 +3668,8 @@ bool CacheAllocator<CacheTrait>::cleanupStrayShmSegments(
36683668 // Any other concurrent process can not be attached to the segments or
36693669 // even if it does, we want to mark it for destruction.
36703670 ShmManager::removeByName (cacheDir, detail::kShmInfoName , posix);
3671- ShmManager::removeByName (cacheDir, detail::kShmCacheName , posix);
3671+ ShmManager::removeByName (cacheDir, detail::kShmCacheName
3672+ + std::to_string (0 ), posix);
36723673 ShmManager::removeByName (cacheDir, detail::kShmHashTableName , posix);
36733674 ShmManager::removeByName (cacheDir, detail::kShmChainedItemHashTableName ,
36743675 posix);
0 commit comments