cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-library Mailing List Archives

Re: threading problem on windows

From: Gisle Vanem <giva_at_bgnett.no>
Date: Sun, 4 Jul 2004 13:10:22 +0200

"Michael Mastroianni" said:

> When I run a lot of threads (like 150), I get blowups in
>
> gethostbyname_thread in hostthre.c
>
> in particular, I blow up on the line:
>
> he = gethostbyname (conn->async.hostname);

You mean it is NULL or some huge illegal value? I don't see how
that can happen. The get*_thread() functions doesn't modify that
string at all. Unless someone else stepping on 'conn->async'.

Do you have an example program I could try?

> I got c-ares, built it, gave my curllib project the directories, told it
> to link against libares.lib, and defined USE_ARES in the project settings.
> Still, I end up here.

That shouldn't happen; USE_THREAD_GET* isn't defined unless you defined
it outside setup.h youself. Looks like your debugger isn't giving you the true
story or the bug is elsewhere.

Try to build libcurl with -DCURLDEBUG and watch for allocation errors.
Look at src/main.c and curl_memdebug("memdump") for how that's done.

--gv
Received on 2004-07-04

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET