Skip to content

Commit

Permalink
Use GetLocalMRPConfig for LivenessCheckTimerTimeout (#31466)
Browse files Browse the repository at this point in the history
* Use GetLocalMRPConfig for LivenessCheckTimerTimeout

* address comment

* Restyled by clang-format

---------

Co-authored-by: Restyled.io <commits@restyled.io>
  • Loading branch information
2 people authored and pull[bot] committed Feb 5, 2024
1 parent a09b58c commit 990f898
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/app/ReadClient.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -945,7 +945,9 @@ CHIP_ERROR ReadClient::ComputeLivenessCheckTimerTimeout(System::Clock::Timeout *
// TODO: We need to find a good home for this logic that will correctly compute this based on transport. For now, this will
// suffice since we don't use TCP as a transport currently and subscriptions over BLE aren't really a thing.
//
const auto & ourMrpConfig = GetDefaultMRPConfig();
const auto & localMRPConfig = GetLocalMRPConfig();
const auto & defaultMRPConfig = GetDefaultMRPConfig();
const auto & ourMrpConfig = localMRPConfig.ValueOr(defaultMRPConfig);
auto publisherTransmissionTimeout =
GetRetransmissionTimeout(ourMrpConfig.mActiveRetransTimeout, ourMrpConfig.mIdleRetransTimeout,
System::SystemClock().GetMonotonicTimestamp(), ourMrpConfig.mActiveThresholdTime);
Expand Down

0 comments on commit 990f898

Please sign in to comment.