curl-library
Re: curl-library Digest, Vol 74, Issue 27
Date: Mon, 17 Oct 2011 13:30:14 +0200
On Sun, Oct 16, 2011 at 12:00 PM, Daniel Stenberg <daniel_at_haxx.se> wrote:
> 1 - although relatively recent (it didn't exist in 7.19.5) this code has
> > been present in several curl versions, so is the fact that it appears on
> our
> > embedded Linux platform a symptom of some deeper issue, or just bad luck?
>
> I would say bad luck (or possibly due to a rare combination of problem and
> your particular libc implementation/version), but I've not really dug into
> what system call that gets used after connect() that clobbers errno and why
> it
> haven't hurt more people...
>
No problem, it just struck me as odd - you're probably right...
>
> > 2 - I don't see any possible side effects, but can you confirm that no
> ill
> > side effects could be caused by this patch?
>
> The only little flaw I could spot is that 'error' could be used
> uninitialized
> in some code paths so it needs to be initialized to zero to make sure that
> doesn't occur.
>
I don't think there actually exists a path towards the if(-1==rc) that
combines rc==-1 and error == undefined but an initialized variable won't
hurt :-)
>
> Fix was pushed as commit 1a416cd27a37d. Thanks a lot!
>
Thank you for curl !
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2011-10-17