sdbusplus: avoid deprecated phosphor::Timer
sdbusplus had an older type named `phosphor::Timer` which was
recently renamed to `sdbusplus::Timer`. Update the code to use
the new type alias.
Change-Id: I68d3968bcb359bee5ea0c9e695572b68fcf34136
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/requester/handler.hpp b/requester/handler.hpp
index 02c5d02..5fc5f7b 100644
--- a/requester/handler.hpp
+++ b/requester/handler.hpp
@@ -197,7 +197,7 @@
pldmTransport, requestMsg->key.eid, event,
std::move(requestMsg->reqMsg), numRetries, responseTimeOut,
verbose);
- auto timer = std::make_unique<phosphor::Timer>(
+ auto timer = std::make_unique<sdbusplus::Timer>(
event.get(), std::bind(&Handler::instanceIdExpiryCallBack, this,
requestMsg->key));
@@ -335,7 +335,7 @@
*/
using RequestValue =
std::tuple<std::unique_ptr<RequestInterface>, ResponseHandler,
- std::unique_ptr<phosphor::Timer>>;
+ std::unique_ptr<sdbusplus::Timer>>;
// Manage the requests of responders base on MCTP EID
std::map<mctp_eid_t, std::shared_ptr<EndpointMessageQueue>>
diff --git a/requester/request.hpp b/requester/request.hpp
index 27d94fc..cb4e026 100644
--- a/requester/request.hpp
+++ b/requester/request.hpp
@@ -98,8 +98,8 @@
sdeventplus::Event& event; //!< reference to PLDM daemon's main event loop
uint8_t numRetries; //!< number of request retries
std::chrono::milliseconds
- timeout; //!< time to wait between each retry in milliseconds
- phosphor::Timer timer; //!< manages starting timers and handling timeouts
+ timeout; //!< time to wait between each retry in milliseconds
+ sdbusplus::Timer timer; //!< manages starting timers and handling timeouts
/** @brief Sends the PLDM request message
*
diff --git a/requester/test/request_test.cpp b/requester/test/request_test.cpp
index 51b337d..25d2c32 100644
--- a/requester/test/request_test.cpp
+++ b/requester/test/request_test.cpp
@@ -88,7 +88,7 @@
EXPECT_EQ(rc, PLDM_SUCCESS);
auto requestStopCallback = [&](void) { request.stop(); };
- phosphor::Timer timer(event.get(), requestStopCallback);
+ sdbusplus::Timer timer(event.get(), requestStopCallback);
timer.start(duration_cast<microseconds>(seconds(1)));
waitEventExpiry(milliseconds(500));