[2/3] file: fix missing include for PATH_MAX constant
diff mbox series

Message ID b867217d30569b84e098ca013c44e07e1df598fb.1549290423.git.ps@pks.im
State New
Headers show
  • [1/3] configure.ac: more carefully detect availability of res_querydomain(3)
Related show

Commit Message

Patrick Steinhardt Feb. 4, 2019, 2:31 p.m. UTC
While making use of the PATH_MAX constant, "file.c" does not include the
"limits.h" header. While it is being transitively included via other
headers on most platforms, it is not on e.g. musl-based systems.

Add the include to fix compilation.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
 support/misc/file.c | 1 +
 1 file changed, 1 insertion(+)

diff mbox series

diff --git a/support/misc/file.c b/support/misc/file.c
index 4065376..e7c3819 100644
--- a/support/misc/file.c
+++ b/support/misc/file.c
@@ -27,6 +27,7 @@ 
 #include <dirent.h>
 #include <stdlib.h>
 #include <stdbool.h>
+#include <limits.h>
 #include "xlog.h"
 #include "misc.h"