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: I41103c892db258a85640aa1442acd9a295c8a847
diff --git a/host_reset_recovery.cpp b/host_reset_recovery.cpp
index 7898622..fe94f72 100644
--- a/host_reset_recovery.cpp
+++ b/host_reset_recovery.cpp
@@ -38,7 +38,7 @@
constexpr auto SYSTEMD_INTERFACE = "org.freedesktop.systemd1.Manager";
constexpr auto HOST_STATE_QUIESCE_TGT = "obmc-host-quiesce@0.target";
-bool wasHostBooting(sdbusplus::bus::bus& bus)
+bool wasHostBooting(sdbusplus::bus_t& bus)
{
try
{
@@ -64,7 +64,7 @@
info("Host was booting before BMC reboot: {BOOTPROGRESS}",
"BOOTPROGRESS", bootProgress);
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
error("Error reading BootProgress, error {ERROR}, service {SERVICE}, "
"path {PATH}",
@@ -76,7 +76,7 @@
return true;
}
-void createErrorLog(sdbusplus::bus::bus& bus)
+void createErrorLog(sdbusplus::bus_t& bus)
{
try
{
@@ -95,7 +95,7 @@
method.append(errorMessage, level, additionalData);
auto resp = bus.call(method);
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
error(
"sdbusplus D-Bus call exception, error {ERROR}, objpath {OBJPATH}, "
@@ -126,7 +126,7 @@
return !f.good();
}
-void moveToHostQuiesce(sdbusplus::bus::bus& bus)
+void moveToHostQuiesce(sdbusplus::bus_t& bus)
{
try
{
@@ -138,7 +138,7 @@
bus.call_noreply(method);
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
error("sdbusplus call exception starting quiesce target: {ERROR}",
"ERROR", e);