]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
prevent harmless compiler warning
authorDaniel Stenberg <daniel@haxx.se>
Thu, 4 Mar 2004 12:57:12 +0000 (12:57 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Thu, 4 Mar 2004 12:57:12 +0000 (12:57 +0000)
lib/url.c

index 91ed90460bd0ae89a75f8d8073532c05a9cda99a..e189de5d1371c34caad5d79db18f8aeea7900b20 100644 (file)
--- a/lib/url.c
+++ b/lib/url.c
@@ -1856,9 +1856,6 @@ static CURLcode ConnectPlease(struct connectdata *conn,
 static void verboseconnect(struct connectdata *conn,
                            struct Curl_dns_entry *dns)
 {
-#ifdef HAVE_INET_NTOA_R
-  char ntoa_buf[64];
-#endif
   struct SessionHandle *data = conn->data;
 
   /* Figure out the ip-number and display the first host name it shows: */
@@ -1896,6 +1893,9 @@ static void verboseconnect(struct connectdata *conn,
   }
 #else
   {
+#ifdef HAVE_INET_NTOA_R
+    char ntoa_buf[64];
+#endif
     Curl_addrinfo *hostaddr=dns?dns->addr:NULL;
     struct in_addr in;
     (void) memcpy(&in.s_addr, &conn->serv_addr.sin_addr, sizeof (in.s_addr));