summaryrefslogtreecommitdiff
path: root/redfish-core/lib/certificate_service.hpp
diff options
context:
space:
mode:
authorEd Tanous <edtanous@google.com>2022-02-27 08:42:46 +0300
committerEd Tanous <ed@tanous.net>2022-03-22 20:53:16 +0300
commitb9d36b4791d77a47e1f3c5c4564fcdf7cc68c115 (patch)
tree22a37e506310ded94a45aed79799929f94bac330 /redfish-core/lib/certificate_service.hpp
parenta2dd60a69046cdda90077463f614140aeb91edc4 (diff)
downloadbmcweb-b9d36b4791d77a47e1f3c5c4564fcdf7cc68c115.tar.xz
Consitently use dbus::utility types
This saves about 4k on the binary size Tested: Redfish service validator passes. Signed-off-by: Ed Tanous <edtanous@google.com> Change-Id: I9546227a19c691b1aecb80e80307889548c0293f
Diffstat (limited to 'redfish-core/lib/certificate_service.hpp')
-rw-r--r--redfish-core/lib/certificate_service.hpp18
1 files changed, 6 insertions, 12 deletions
diff --git a/redfish-core/lib/certificate_service.hpp b/redfish-core/lib/certificate_service.hpp
index 6d17a6173b..4882ec30f8 100644
--- a/redfish-core/lib/certificate_service.hpp
+++ b/redfish-core/lib/certificate_service.hpp
@@ -452,11 +452,9 @@ inline void requestRoutesCertificateActionGenerateCSR(App& app)
messages::internalError(asyncResp->res);
return;
}
- std::vector<std::pair<
- std::string,
- std::vector<std::pair<std::string,
- dbus::utility::DbusVariantType>>>>
- interfacesProperties;
+
+ dbus::utility::DBusInteracesMap interfacesProperties;
+
sdbusplus::message::object_path csrObjectPath;
m.read(csrObjectPath, interfacesProperties);
BMCWEB_LOG_DEBUG << "CSR object added" << csrObjectPath.str;
@@ -572,13 +570,12 @@ static void getCertificateProperties(
const std::string& objectPath, const std::string& service, long certId,
const std::string& certURL, const std::string& name)
{
- using PropertiesMap =
- boost::container::flat_map<std::string, dbus::utility::DbusVariantType>;
BMCWEB_LOG_DEBUG << "getCertificateProperties Path=" << objectPath
<< " certId=" << certId << " certURl=" << certURL;
crow::connections::systemBus->async_method_call(
- [asyncResp, certURL, certId, name](const boost::system::error_code ec,
- const PropertiesMap& properties) {
+ [asyncResp, certURL, certId,
+ name](const boost::system::error_code ec,
+ const dbus::utility::DBusPropertiesMap& properties) {
if (ec)
{
BMCWEB_LOG_ERROR << "DBUS response error: " << ec;
@@ -666,9 +663,6 @@ static void getCertificateProperties(
certs::certPropIntf);
}
-using GetObjectType =
- std::vector<std::pair<std::string, std::vector<std::string>>>;
-
/**
* Action to replace an existing certificate
*/