Skip to content

Commit 2807da0

Browse files
committed
Thread: continuous discovery
1 parent f8e141a commit 2807da0

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/platform/OpenThread/GenericThreadStackManagerImpl_OpenThread.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -961,6 +961,7 @@ template <class ImplClass>
961961
void GenericThreadStackManagerImpl_OpenThread<ImplClass>::TryNextNetwork()
962962
{
963963
otSockAddr targetAddr;
964+
bool isRunning = otSeekerIsRunning(mOTInst);
964965

965966
if (otSeekerSetUpNextConnection(mOTInst, &targetAddr) == OT_ERROR_NONE)
966967
{
@@ -969,7 +970,7 @@ void GenericThreadStackManagerImpl_OpenThread<ImplClass>::TryNextNetwork()
969970

970971
DeviceLayer::SystemLayer().ScheduleLambda([this]() { SendRendezvousAnnouncement(); });
971972
}
972-
else if (otSeekerIsRunning(mOTInst))
973+
else if (isRunning)
973974
{
974975
otSeekerStop(mOTInst);
975976

0 commit comments

Comments
 (0)