cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Libcurl and c-ares

From: Jeff Pohlmeyer <yetanothergeek_at_gmail.com>
Date: Fri, 1 Jan 2010 01:07:39 -0600

On Thu, Dec 31, 2009 at 7:02 PM, Adrian Michel wrote:

> I assume libcurl has built-in c-ares support and it doesn't require
> any additional h or lib files. Could you please confirm this.

If you built also the curl command-line tool, you can try
curl --version and see if async DNS is mentioned on the
"features" line.

Or you could compile a simple test app, something like:

#include <curl/curl.h>
int main()
{
 curl_version_info_data*info=curl_version_info(CURLVERSION_NOW);
 if (info->features&CURL_VERSION_ASYNCHDNS) {
   printf( "ares enabled\n");
 } else {
   printf( "ares NOT enabled\n");
 }
 return 0;
}

> BTW, why doesn't libcurl use ares by default?

There was a brief mention about this back in August:
  http://curl.haxx.se/mail/lib-2009-08/0014.html

 - Jeff
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-01-01