Provide a fallback for PATH_MAX.
authorBruno Haible <bruno@clisp.org>
Fri, 6 Oct 2006 21:20:20 +0000 (21:20 +0000)
committerBruno Haible <bruno@clisp.org>
Fri, 6 Oct 2006 21:20:20 +0000 (21:20 +0000)
lib/ChangeLog
lib/clean-temp.c

index f911467..b9e32d6 100644 (file)
@@ -1,3 +1,8 @@
+2006-10-06  Bruno Haible  <bruno@clisp.org>
+
+       * clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
+       Reported by Eric Blake.
+
 2006-09-29  Bruno Haible  <bruno@clisp.org>
        and Paul Eggert  <eggert@cs.ucla.edu>
 
index 1d1e07c..12b9b6c 100644 (file)
 
 #define _(str) gettext (str)
 
+/* GNU Hurd doesn't have PATH_MAX.  */
+#ifndef PATH_MAX
+# ifdef MAXPATHLEN
+#  define PATH_MAX MAXPATHLEN
+# else
+#  define PATH_MAX 1024
+# endif
+#endif
+
 #ifndef uintptr_t
 # define uintptr_t unsigned long
 #endif