|
@@ -982,8 +982,8 @@ void slimproto(log_level level, char *server, u8_t mac[6], const char *name, con
|
|
|
// in embedded we give up after a while no matter what
|
|
|
if (++failed_connect > MAX_SERVER_RETRIES && !server) {
|
|
|
slimproto_ip = serv_addr.sin_addr.s_addr = discover_server(NULL, MAX_SERVER_RETRIES);
|
|
|
- if (!slimproto_ip) return;
|
|
|
- } else if (reconnect && MAX_SERVER_RETRIES && failed_connect > 5 * MAX_SERVER_RETRIES) return;
|
|
|
+ if (!slimproto_ip && !output.external) return;
|
|
|
+ } else if (reconnect && MAX_SERVER_RETRIES && failed_connect > 5 * MAX_SERVER_RETRIES && !output.external) return;
|
|
|
#else
|
|
|
// rediscover server if it was not set at startup or exit
|
|
|
if (!server && ++failed_connect > 5) {
|