Move getErrCodeMsg API to common_utility
This commit moves the getErrCodeMsg API from vpd_specific_utility to
common_utility file, to make it accessible to the other utility files.
Change-Id: Ib0aeeb2386ba2c55f2447d65a3be18b76eff46f3
Signed-off-by: Rekha Aparna <vrekhaaparna@ibm.com>
diff --git a/vpd-manager/oem-handler/ibm_handler.cpp b/vpd-manager/oem-handler/ibm_handler.cpp
index df25af9..ae62a70 100644
--- a/vpd-manager/oem-handler/ibm_handler.cpp
+++ b/vpd-manager/oem-handler/ibm_handler.cpp
@@ -64,7 +64,7 @@
{
logging::logMessage(
"Failed to check if backup & restore required. Error : " +
- vpdSpecificUtility::getErrCodeMsg(l_errCode));
+ commonUtility::getErrCodeMsg(l_errCode));
}
// Instantiate Listener object
@@ -181,8 +181,8 @@
{
logging::logMessage(
"Failed to get inventory object path from JSON for FRU [" +
- l_fruPath + "], error : " +
- vpdSpecificUtility::getErrCodeMsg(l_errCode));
+ l_fruPath +
+ "], error : " + commonUtility::getErrCodeMsg(l_errCode));
}
o_failedPathList.push_back(l_fruPath);
@@ -321,9 +321,8 @@
if (l_powerVsJsonObj.empty())
{
- throw std::runtime_error(
- "PowerVS Json not found. Error : " +
- vpdSpecificUtility::getErrCodeMsg(l_errCode));
+ throw std::runtime_error("PowerVS Json not found. Error : " +
+ commonUtility::getErrCodeMsg(l_errCode));
}
checkAndUpdatePowerVsVpd(l_powerVsJsonObj, l_failedPathList);