$NetBSD: patch-ar,v 1.1.1.1 2007/10/17 21:35:53 agc Exp $

--- lib/user/hostinfoPosix.c	2007/09/29 10:16:41	1.1
+++ lib/user/hostinfoPosix.c	2007/09/29 10:19:15
@@ -694,8 +694,8 @@
          e = s + strlen(s);
 
          /* Skip leading and trailing while spaces */
-         for (; s < e && isspace(*s); s++);
-         for (; s < e && isspace(e[-1]); e--);
+         for (; s < e && isspace((unsigned)*s); s++);
+         for (; s < e && isspace((unsigned)e[-1]); e--);
          *e = 0;
          
          /* Free previous value */
@@ -1071,7 +1071,9 @@
 {
    int s, fd;
    struct sigaction sa;
+#ifdef RLIMIT_AS
    struct rlimit rlim;
+#endif
 #ifdef __linux__
    int err;
    uid_t euid;
@@ -1095,10 +1097,12 @@
       }
    }
 
+#ifdef RLIMIT_AS
    if (getrlimit(RLIMIT_AS, &rlim) == 0) {
       rlim.rlim_cur = rlim.rlim_max;
       setrlimit(RLIMIT_AS, &rlim);
    }
+#endif
 
 #ifdef __linux__
    /*
