Closed
Description
Actually documentation says that it can be undefined if no real limit is applicable.
Would this be OK?:
diff --git a/tinydir.h b/tinydir.h
index 324f9f6..7863564 100644
--- a/tinydir.h
+++ b/tinydir.h
@@ -89,7 +89,9 @@ extern "C" {
# define _TINYDIR_PATH_MAX MAX_PATH
#elif defined __linux__
# include <limits.h>
-# define _TINYDIR_PATH_MAX PATH_MAX
+# ifdef PATH_MAX
+# define _TINYDIR_PATH_MAX PATH_MAX
+# endif
#elif defined(__unix__) || (defined(__APPLE__) && defined(__MACH__))
# include <sys/param.h>
# if defined(BSD)
Metadata
Assignees
Labels
No labels
Activity