cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: CURL_SOCKET_BAD patches

From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Thu, 11 Mar 2004 14:12:12 +0100 (CET)

On Thu, 11 Mar 2004, Gisle Vanem wrote:

> Some patches to make an almost silent "gcc -Wall -W2" compile on MingW.
> Mostly replacing '-1' with 'CURL_SOCKET_BAD'.

Ah, goodie. I tried to change all of them but I failed miserably! Thanks for
covering up for me.

> My only concern is a patch like:
> - if (sockfd < 0) {
> + if (sockfd == CURL_SOCKET_BAD) {
>
> But I've yet to hear of a stack returning < -1 on fail.

I would say this is safe to do. I applied and committed!

-- 
    Daniel Stenberg -- http://curl.haxx.se/ -- http://daniel.haxx.se/
   [[ Do not send mails to this email address. They won't reach me. ]]
Received on 2004-03-11