Skip to content

Commit 0afe72d

Browse files
committed
Removing retrying to get the host by name if it fails
1 parent a0ef198 commit 0afe72d

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/utility/wifi_drv.cpp

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -752,17 +752,12 @@ int WiFiDrv::getHostByName(IPAddress& aResult)
752752

753753
int WiFiDrv::getHostByName(const char* aHostname, IPAddress& aResult)
754754
{
755-
uint8_t retry = 10;
756755
if (reqHostByName(aHostname))
757756
{
758-
while(!getHostByName(aResult) && --retry > 0)
759-
{
760-
delay(1000);
761-
}
757+
return getHostByName(aResult);
762758
}else{
763759
return 0;
764760
}
765-
return (retry>0);
766761
}
767762

768763
const char* WiFiDrv::getFwVersion()

0 commit comments

Comments
 (0)