From: Daniel Stenberg Date: Wed, 30 Jun 2004 11:32:16 +0000 (+0000) Subject: simplified the check for when to free() the buf data X-Git-Tag: curl-7_12_1~175 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c7a9e07909484c30707bcae70d5eae3e44d91b71;p=thirdparty%2Fcurl.git simplified the check for when to free() the buf data --- diff --git a/lib/hostip4.c b/lib/hostip4.c index f380d3ef8e..b0196d15ac 100644 --- a/lib/hostip4.c +++ b/lib/hostip4.c @@ -362,8 +362,8 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn, if(h) { ai = Curl_he2ai(h, port); - if (h == buf) /* used a *_r() function */ - free(h); + if (buf) /* used a *_r() function */ + free(buf); } return ai;