cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: fail to `malloc` pointers after a call to curl_easy_perform.

From: Alex Bligh <alex_at_alex.org.uk>
Date: Tue, 19 Jan 2016 20:26:06 +0000

On 19 Jan 2016, at 18:54, ataro <ataro_at_protonmail.ch> wrote:

> Both could have explained it better. In most cases a function will
> document with which of its return values errno has been set and so it
> may not be necessary to set errno to 0 beforehand. In this case though
> you must.

I believe it is legal for functions to set errno but not return an
error though I have no idea whether libcurl or anything it
calls might do this. errno can only be trusted if an error is
returned.

-- 
Alex Bligh
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2016-01-19