From: Daniel Stenberg Date: Thu, 10 Feb 2011 21:21:57 +0000 (+0100) Subject: --keepalive-time: warn if not supported properly X-Git-Tag: curl-7_21_4~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3bb1291fbd4f938bb9b7b3c2fe48b029ee0152d3;p=thirdparty%2Fcurl.git --keepalive-time: warn if not supported properly Since the feature requires support for TCP_KEEPIDLE and TCP_KEEPINTVL to function as documented, it now warns if that support is missing when the option is used. --- diff --git a/src/main.c b/src/main.c index cfff1f9825..1c707f89fc 100644 --- a/src/main.c +++ b/src/main.c @@ -1764,6 +1764,10 @@ static int sockoptcallback(void *clientp, curl_socket_t curlfd, warnf(clientp, "Could not set TCP_KEEPINTVL!\n"); return 0; } +#endif +#if !defined(TCP_KEEPIDLE) || !defined(TCP_KEEPINTVL) + warnf(clientp, "Keep-alive functionality somewhat crippled due to " + "missing support in your operating system!\n"); #endif } }