DORMANTno replies

[PATCH 7/10] Fix header breakage due to redefining PATH_MAX.

From: Ramsay Jones <hidden>
Date: 2016-06-15 22:42:35
Subsystem: the rest · Maintainer: Linus Torvalds

The header builtin.h was, incorrectly, redefining PATH_MAX which
causes a header order dependency in builtin-write-tree.c.  The fix
is to simply include <limits.h> directly to obtain the correct
definition of PATH_MAX.

Signed-off-by: Ramsay Allan Jones <redacted>
---
Note that on Linux 2.2.14, PATH_MAX is define to be 4095.
(Solaris, Mac OSX, *BSD define it as 1024)

 builtin.h |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/builtin.h b/builtin.h
index f12d5e6..7bfff11 100644
--- a/builtin.h
+++ b/builtin.h
@@ -2,10 +2,7 @@ #ifndef BUILTIN_H
 #define BUILTIN_H
 
 #include <stdio.h>
-
-#ifndef PATH_MAX
-# define PATH_MAX 4096
-#endif
+#include <limits.h>
 
 extern const char git_version_string[];
 
-- 
1.4.1

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help