sdbusplus: use shorter type aliases
The sdbusplus headers provide shortened aliases for many types.
Switch to using them to provide better code clarity and shorter
lines. Possible replacements are for:
* bus_t
* exception_t
* manager_t
* match_t
* message_t
* object_t
* slot_t
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Change-Id: I8e2242adb79be342562c9b7f3d2153dfdf578085
diff --git a/libpldmresponder/bios.cpp b/libpldmresponder/bios.cpp
index e6f4a6c..2306ad9 100644
--- a/libpldmresponder/bios.cpp
+++ b/libpldmresponder/bios.cpp
@@ -125,7 +125,7 @@
timeUsec = pldm::utils::DBusHandler().getDbusProperty<EpochTimeUS>(
bmcTimePath, "Elapsed", timeInterface);
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
std::cerr << "Error getting time, PATH=" << bmcTimePath
<< " TIME INTERACE=" << timeInterface << "\n";
diff --git a/libpldmresponder/bios_config.cpp b/libpldmresponder/bios_config.cpp
index 3649c78..704fa33 100644
--- a/libpldmresponder/bios_config.cpp
+++ b/libpldmresponder/bios_config.cpp
@@ -958,10 +958,10 @@
constexpr auto objInterface = "xyz.openbmc_project.BIOSConfig.Manager";
using namespace sdbusplus::bus::match::rules;
- auto updateBIOSMatch = std::make_unique<sdbusplus::bus::match::match>(
+ auto updateBIOSMatch = std::make_unique<sdbusplus::bus::match_t>(
pldm::utils::DBusHandler::getBus(),
propertiesChanged(objPath, objInterface),
- [this](sdbusplus::message::message& msg) {
+ [this](sdbusplus::message_t& msg) {
constexpr auto propertyName = "PendingAttributes";
using Value =
diff --git a/libpldmresponder/bios_config.hpp b/libpldmresponder/bios_config.hpp
index 18e13b0..381ff0a 100644
--- a/libpldmresponder/bios_config.hpp
+++ b/libpldmresponder/bios_config.hpp
@@ -159,7 +159,7 @@
using DbusChObjProperties = std::map<propName, pldm::utils::PropertyValue>;
// vector to catch the D-Bus property change signals for BIOS attributes
- std::vector<std::unique_ptr<sdbusplus::bus::match::match>> biosAttrMatch;
+ std::vector<std::unique_ptr<sdbusplus::bus::match_t>> biosAttrMatch;
/** @brief Method to update a BIOS attribute when the corresponding Dbus
* property is changed
@@ -188,12 +188,11 @@
{
using namespace sdbusplus::bus::match::rules;
biosAttrMatch.push_back(
- std::make_unique<sdbusplus::bus::match::match>(
+ std::make_unique<sdbusplus::bus::match_t>(
pldm::utils::DBusHandler::getBus(),
propertiesChanged(dBusMap->objectPath,
dBusMap->interface),
- [this,
- biosAttrIndex](sdbusplus::message::message& msg) {
+ [this, biosAttrIndex](sdbusplus::message_t& msg) {
DbusChObjProperties props;
std::string iface;
msg.read(iface, props);