aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/server/sockfilt.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/server/sockfilt.c b/tests/server/sockfilt.c
index 5e13b8ad1..9704eaede 100644
--- a/tests/server/sockfilt.c
+++ b/tests/server/sockfilt.c
@@ -399,13 +399,15 @@ static curl_socket_t sockdaemon(curl_socket_t sock,
#endif /* ENABLE_IPV6 */
int flag = 1;
int rc;
- int maxretr = 100;
+ int maxretr = 12;
+ int delay= 10;
rc = setsockopt(sock, SOL_SOCKET, SO_REUSEADDR,
(void *)&flag, sizeof(flag));
while ((rc < 0) && maxretr) {
maxretr--;
- go_sleep(50);
+ go_sleep(delay);
+ delay *= 2; /* double the sleep for next attempt */
rc = setsockopt(sock, SOL_SOCKET, SO_REUSEADDR,
(void *)&flag, sizeof(flag));
}