cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Yet another minor patch

From: Yang Tse <yangsita_at_gmail.com>
Date: Sat, 26 Nov 2005 16:32:26 +0100

Daniel, et all

This one tries to fix the fact that IRIX 6.2 does not have a prototype
for function inet_pton(). I think the conditions under which the
prototype is defined only target IRIX 6.2, but of course the automatic
builds shall be watched, specially all IRIX ones.

diff -urp c:\f\curl-old/curl/lib/inet_pton.h c:\f\curl-new/curl/lib/inet_pton.h
--- c:\f\curl-old/curl/lib/inet_pton.h 2005-11-25 23:20:02.000000000 +0100
+++ c:\f\curl-new/curl/lib/inet_pton.h 2005-11-26 16:19:19.265625000 +0100
@@ -27,6 +27,20 @@

 int Curl_inet_pton(int, const char *, void *);

+/*
+ Configure finds out that IRIX 6.2 has inet_pton().
+ But IRIX 6.2 does not provide its prototype in any
+ header file. We prototype it here only for IRIX 6.2
+*/
+
+#if defined(__sgi) && defined(__mips) && !defined(__GNUC__)
+#if defined(_COMPILER_VERSION) && _COMPILER_VERSION < 700
+#ifdef HAVE_INET_PTON
+int inet_pton(int af, const char *src, void *dst);
+#endif
+#endif
+#endif
+
 #ifdef HAVE_INET_PTON
 #ifdef HAVE_ARPA_INET_H
 #include <arpa/inet.h>

Regards,
Yang
Received on 2005-11-26