File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ int DNSClient::inet_aton(const char* address, IPAddress& result)
8585 return 1 ;
8686}
8787
88- int DNSClient::getHostByName (const char * aHostname, IPAddress& aResult)
88+ int DNSClient::getHostByName (const char * aHostname, IPAddress& aResult, uint16_t timeout )
8989{
9090 int ret = 0 ;
9191
@@ -118,7 +118,7 @@ int DNSClient::getHostByName(const char* aHostname, IPAddress& aResult)
118118 int wait_retries = 0 ;
119119 ret = TIMED_OUT;
120120 while ((wait_retries < 3 ) && (ret == TIMED_OUT)) {
121- ret = ProcessResponse (5000 , aResult);
121+ ret = ProcessResponse (timeout , aResult);
122122 wait_retries++;
123123 }
124124 }
Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ class DNSClient
2626 @result 1 if aIPAddrString was successfully converted to an IP address,
2727 else error code
2828 */
29- int getHostByName (const char * aHostname, IPAddress& aResult);
29+ int getHostByName (const char * aHostname, IPAddress& aResult, uint16_t timeout= 5000 );
3030
3131protected:
3232 uint16_t BuildRequest (const char * aName);
You can’t perform that action at this time.
0 commit comments