about summary refs log tree commit diff
path: root/nss/bug-erange.c
diff options
context:
space:
mode:
Diffstat (limited to 'nss/bug-erange.c')
-rw-r--r--nss/bug-erange.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/nss/bug-erange.c b/nss/bug-erange.c
index 5e535a0fe4..b709418b5c 100644
--- a/nss/bug-erange.c
+++ b/nss/bug-erange.c
@@ -6,6 +6,7 @@
 #include <string.h>
 #include <stdio.h>
 #include <stdlib.h>
+#include <unistd.h>
 
 int
 main (void)
@@ -35,6 +36,13 @@ main (void)
   if (res != 0 || hp == NULL)
     {
       printf ("gethostbyname_r failed: %s (errno: %m)\n", strerror (res));
+
+      if (access ("/etc/resolv.conf", R_OK))
+	{
+	  puts ("DNS probably not set up");
+	  return 0;
+	}
+
       return 1;
     }