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_state_manager.cpp b/host_state_manager.cpp
index f1709cd..6ff1f56 100644
--- a/host_state_manager.cpp
+++ b/host_state_manager.cpp
@@ -67,7 +67,7 @@
{
this->bus.call_noreply(method);
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
error("Failed to subscribe to systemd signals: {ERROR}", "ERROR", e);
elog<InternalFailure>();
@@ -170,7 +170,7 @@
auto result = this->bus.call(method);
result.read(unitTargetPath);
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
error("Error in GetUnit call: {ERROR}", "ERROR", e);
return false;
@@ -188,7 +188,7 @@
auto result = this->bus.call(method);
result.read(currentState);
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
error("Error in ActiveState Get: {ERROR}", "ERROR", e);
return false;
@@ -275,14 +275,14 @@
return false;
}
}
- catch (const sdbusplus::exception::exception& e)
+ catch (const sdbusplus::exception_t& e)
{
error("Error in AutoReboot Get, {ERROR}", "ERROR", e);
return false;
}
}
-void Host::sysStateChangeJobRemoved(sdbusplus::message::message& msg)
+void Host::sysStateChangeJobRemoved(sdbusplus::message_t& msg)
{
uint32_t newStateID{};
sdbusplus::message::object_path newStateObjPath;
@@ -339,7 +339,7 @@
}
}
-void Host::sysStateChangeJobNew(sdbusplus::message::message& msg)
+void Host::sysStateChangeJobNew(sdbusplus::message_t& msg)
{
uint32_t newStateID{};
sdbusplus::message::object_path newStateObjPath;