From 651398052568b47413c3055ac8263eced15ebaf7 Mon Sep 17 00:00:00 2001 From: stephb9959 Date: Wed, 17 Jan 2024 10:14:35 -0800 Subject: [PATCH] https://telecominfraproject.atlassian.net/browse/WIFI-13280 Signed-off-by: stephb9959 --- src/RADIUS_Destination.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/RADIUS_Destination.h b/src/RADIUS_Destination.h index 64f44442..aefa2d9a 100644 --- a/src/RADIUS_Destination.h +++ b/src/RADIUS_Destination.h @@ -62,21 +62,29 @@ namespace OpenWifi { Poco::Thread::trySleep(5000); std::uint64_t CurrentDelay = 10, maxDelay=300, LastTry=0, LastKeepAlive=0; while (TryAgain_) { + std::cout << __LINE__ << std::endl; if (!Connected_) { + std::cout << __LINE__ << std::endl; if(!LastTry || (Utils::Now()-LastTry)>CurrentDelay) { LastTry = Utils::Now(); + std::cout << __LINE__ << std::endl; if (!Connect()) { + std::cout << __LINE__ << std::endl; CurrentDelay *= 2; if(CurrentDelay>maxDelay) CurrentDelay=10; } else { + std::cout << __LINE__ << std::endl; CurrentDelay = 10; } } + std::cout << __LINE__ << std::endl; } else if ((Utils::Now() - LastKeepAlive) > Pool_.radsecKeepAlive) { RADIUS::RadiusOutputPacket P(Pool_.authConfig.servers[ServerIndex_].radsecSecret); P.MakeStatusMessage(Pool_.authConfig.servers[ServerIndex_].name); poco_trace(Logger_, fmt::format("{}: Keep-Alive message.", Pool_.authConfig.servers[ServerIndex_].name)); + std::cout << __LINE__ << std::endl; Socket_->sendBytes(P.Data(), P.Len()); + std::cout << __LINE__ << std::endl; LastKeepAlive = Utils::Now(); } Poco::Thread::trySleep(2000);