diff --git a/src/PropertyServer/CacheInfo.h b/src/PropertyServer/CacheInfo.h index 516691c..28326f5 100644 --- a/src/PropertyServer/CacheInfo.h +++ b/src/PropertyServer/CacheInfo.h @@ -47,7 +47,7 @@ class CacheInfoList bool get(const std::string &cacheName, CacheInfo &cacheInfo) { - TC_ThreadWLock rlock(_rwl); + TC_ThreadRLock rlock(_rwl); if(modules[_index].find(cacheName) != modules[_index].end()) { cacheInfo = modules[_index][cacheName]; diff --git a/src/PropertyServer/CacheInfoManager.cpp b/src/PropertyServer/CacheInfoManager.cpp index fdb59f8..541b292 100644 --- a/src/PropertyServer/CacheInfoManager.cpp +++ b/src/PropertyServer/CacheInfoManager.cpp @@ -63,7 +63,7 @@ void CacheInfoManager::reload() bool CacheInfoManager::getModuleInfo(const string &cacheName, CacheModuleInfo &moduleInfo) const { - TC_ThreadWLock rlock(_rwl); + TC_ThreadRLock rlock(_rwl); const map &infos = _moduleInfos[_moduleInfoIndex]; map::const_iterator it = infos.find(cacheName); @@ -75,4 +75,4 @@ bool CacheInfoManager::getModuleInfo(const string &cacheName, CacheModuleInfo &m } return false; -} \ No newline at end of file +}