From 508cba60cbb1e7f2b3421e334b50b61fe700118a Mon Sep 17 00:00:00 2001 From: Qi Luo Date: Sun, 3 Jan 2021 02:50:20 +0000 Subject: [PATCH] Use template hgetall, because we will tune the return types of library functions --- syncd/RedisClient.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/syncd/RedisClient.cpp b/syncd/RedisClient.cpp index 9a8487976..cc389b6c7 100644 --- a/syncd/RedisClient.cpp +++ b/syncd/RedisClient.cpp @@ -672,7 +672,9 @@ std::unordered_map RedisClient::getAttributesFromAsicK { SWSS_LOG_ENTER(); - return m_dbAsic->hgetall(key); + std::unordered_map map; + m_dbAsic->hgetall(key, std::inserter(map, map.end())); + return map; } bool RedisClient::hasNoHiddenKeysDefined() const