From 699dad984681963863422a2d1d7ead9c3641c18d Mon Sep 17 00:00:00 2001 From: Alan Johnston Date: Mon, 26 Jan 2026 13:16:47 -0500 Subject: [PATCH] Update main.c add sleep 1 after each connection refused error --- main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.c b/main.c index 1ff9e86c..29aa70e0 100644 --- a/main.c +++ b/main.c @@ -3004,6 +3004,7 @@ void socket_send(int length) { printf("\nConnection Failed \n"); printf("Error: %s\n", strerror(errno)); error = 1; + sleep(1); // try again error = 0; @@ -3027,6 +3028,7 @@ void socket_send(int length) { printf("\nConnection Failed \n"); printf("Error: %s\n", strerror(errno)); error = 1; + sleep(1); } } if (error == 1) { @@ -3038,7 +3040,6 @@ void socket_send(int length) { pclose(transmit_restartf); sleep(10); // was 5 // sleep if socket connection refused } - sleep(10); } else { socket_open = 1;