cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: cURL Bug? -- Segmentation Fault (fwd)

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Tue, 3 Feb 2009 19:45:08 +0100 (CET)

On Tue, 3 Feb 2009, Daniel Stenberg wrote:

> I use G++ on a Linux Debian Etch with LibCURL3

3 is the ABI number, it is better to tell us the version number. No matter
what, the most recent ABI 3 version is 2.5 years old so you'd be wise to
upgrade...

> curl_easy_setopt(curl, CURLOPT_WRITEDATA, &buffer);

With no write function set, this will clearly lead to crashes. The default
write function is fwrite() and fwrite() surely cannot deal with a pointer to a
'string'...

> With the GDB Tool I saw that the segmentation fault probably comes from
> curl_escape() everytime.

I doubt that, as curl_escape() is never used by libcurl... it is only a
function its provides to the outside!

-- 
  / daniel.haxx.se
Received on 2009-02-03