Subject: Hosts file support for RISC OS

Hosts file support for RISC OS

From: James Bursa <james_at_semichrome.net>
Date: 2005-12-13

This enables support for the hosts file on RISC OS. The second patch is just
because gcc no longer predefines "riscos".

James

diff -d -u -3 -r1.19 ares_private.h
--- ares_private.h 10 Aug 2005 17:03:53 -0000 1.19
+++ ares_private.h 13 Dec 2005 20:42:35 -0000
@@ -62,6 +62,10 @@
 #define PATH_RESOLV_CONF "sys:/etc/resolv.cfg"
 #define PATH_HOSTS "sys:/etc/hosts"

+#elif defined(__riscos__)
+
+#define PATH_HOSTS "InetDBase:Hosts"
+
 #else

 #define PATH_RESOLV_CONF "/etc/resolv.conf"

diff -d -u -3 -r1.34 ares_init.c
--- ares_init.c 21 Aug 2005 21:09:44 -0000 1.34
+++ ares_init.c 13 Dec 2005 20:42:35 -0000
@@ -504,7 +504,7 @@
   if (status == ARES_SUCCESS)
     status = ARES_EOF;

-#elif defined(riscos)
+#elif defined(__riscos__)

   /* Under RISC OS, name servers are listed in the
      system variable Inet$Resolvers, space separated. */
Received on Tue Dec 13 21:52:11 2005