Whamcloud - gitweb
tune2fs.c: define PATH_MAX if it is not defined by the system headers
authorTheodore Ts'o <tytso@mit.edu>
Mon, 20 Nov 2023 02:06:12 +0000 (21:06 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Mon, 20 Nov 2023 02:06:12 +0000 (21:06 -0500)
This is needed to compile on GNU/Hurd.

Addresses-Debian-Bug: #1056145
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
misc/tune2fs.c

index 458f7cf..9ffe0d1 100644 (file)
@@ -51,11 +51,15 @@ extern int optind;
 #include <unistd.h>
 #include <sys/types.h>
 #include <libgen.h>
-#include <limits.h>
+#include <limits.h>    /* for PATH_MAX */
 #ifdef HAVE_SYS_IOCTL_H
 #include <sys/ioctl.h>
 #endif
 
+#ifndef PATH_MAX
+#define PATH_MAX 4096
+#endif
+
 #include "ext2fs/ext2_fs.h"
 #include "ext2fs/ext2fs.h"
 #include "ext2fs/kernel-jbd.h"