From: Daniel Stenberg Date: Thu, 31 Oct 2002 13:09:11 +0000 (+0000) Subject: Disable the DNS cache (by setting the timeout to 0) made libcurl leak X-Git-Tag: curl-7_10_2~30 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5bc78cb724d5cef768ee37878c1837a4af1eabaf;p=curl Disable the DNS cache (by setting the timeout to 0) made libcurl leak memory. Avery Fay brought the example code that proved this. --- diff --git a/lib/hostip.c b/lib/hostip.c index 29d395d0a..1ad6951f3 100644 --- a/lib/hostip.c +++ b/lib/hostip.c @@ -218,11 +218,13 @@ Curl_addrinfo *Curl_resolv(struct SessionHandle *data, } #endif +#if 0 /* If the host cache timeout is 0, we don't do DNS cach'ing so fall through */ if (data->set.dns_cache_timeout == 0) { return Curl_getaddrinfo(data, hostname, port, &bufp); } +#endif time(&now);