cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Using libcurl in a multithreaded app

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Mon, 12 Jun 2006 16:17:02 +0200 (CEST)

On Sun, 11 Jun 2006, securehell_at_hushmail.com wrote:

> No, I'm just doing straight HTTP GET commands. I believe my problem is
> related to intermittently running out of memory but I don't know whether the
> problem rests with libcurl.

Lots of people have used libcurl multi-threaded with no problems and I am not
aware of any such problems in recent libcurls, so I honestly believe this
problem is caused by your app.

> I actually went through the libcurl source code and did not find any mallocs
> that were unchecked (good code writing, guys).

I do entertain myself by running ./runtests.pl -t at times, which runs curl
tests and makes sure that every malloc call used fails once and that (lib)curl
always behaves nicely...

> Unfortunately the stack gets smashed often and a gdb backtrace doesn't yield
> much helpful information.

That too indicates that your program is doing something bad.

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2006-06-12