{"thread":{"id":"5082","subject":"[PATCH 7/10] Fix header breakage due to redefining PATH_MAX.","startedAt":"2006-08-02T01:03:41Z","lastAt":"2006-08-02T01:03:41Z","messageCount":1,"participants":["Ramsay Jones"],"isPatch":true,"patchVersion":1,"patchTotal":10},"messages":[{"id":"24539","messageId":"00ba01c6b5cf$7e9b4300$c47eedc1@ramsay1.demon.co.uk","threadId":"5082","inReplyTo":null,"subject":"[PATCH 7/10] Fix header breakage due to redefining PATH_MAX.","fromName":"Ramsay Jones","fromEmail":"ramsay@ramsay1.demon.co.uk","sentAt":"2006-08-02T01:03:41Z","receivedAt":"2006-08-02T01:03:41Z","isPatch":true,"sender":{"key":"ramsay@ramsayjones.plus.com","avatar":"https://avatars.githubusercontent.com/u/33702710?v=4"},"body":"The header builtin.h was, incorrectly, redefining PATH_MAX which\ncauses a header order dependency in builtin-write-tree.c.  The fix\nis to simply include <limits.h> directly to obtain the correct\ndefinition of PATH_MAX.\n\nSigned-off-by: Ramsay Allan Jones <ramsay@ramsay1.demon.co.uk>\n---\nNote that on Linux 2.2.14, PATH_MAX is define to be 4095.\n(Solaris, Mac OSX, *BSD define it as 1024)\n\n builtin.h |    5 +----\n 1 files changed, 1 insertions(+), 4 deletions(-)\n\ndiff --git a/builtin.h b/builtin.h\nindex f12d5e6..7bfff11 100644\n--- a/builtin.h\n+++ b/builtin.h\n@@ -2,10 +2,7 @@ #ifndef BUILTIN_H\n #define BUILTIN_H\n \n #include <stdio.h>\n-\n-#ifndef PATH_MAX\n-# define PATH_MAX 4096\n-#endif\n+#include <limits.h>\n \n extern const char git_version_string[];\n \n-- \n1.4.1\n\n\nFrom 14324992ff3a9b43c3ac9c869ef40cf59eeac245 Mon Sep 17 00:00:00 2001\nFrom: Ramsay Allan Jones <ramsay@ramsay1.demon.co.uk>\nDate: Sun, 30 Jul 2006 17:00:40 +0100\nSubject: [PATCH 7/10] Fix header breakage due to redefining PATH_MAX.\n\nThe header builtin.h was, incorrectly, redefining PATH_MAX which\ncauses a header order dependency in builtin-write-tree.c.  The fix\nis to simply include <limits.h> directly to obtain the correct\ndefinition of PATH_MAX.\n\nSigned-off-by: Ramsay Allan Jones <ramsay@ramsay1.demon.co.uk>\n---\n builtin.h |    5 +----\n 1 files changed, 1 insertions(+), 4 deletions(-)\n\ndiff --git a/builtin.h b/builtin.h\nindex f12d5e6..7bfff11 100644\n--- a/builtin.h\n+++ b/builtin.h\n@@ -2,10 +2,7 @@ #ifndef BUILTIN_H\n #define BUILTIN_H\n \n #include <stdio.h>\n-\n-#ifndef PATH_MAX\n-# define PATH_MAX 4096\n-#endif\n+#include <limits.h>\n \n extern const char git_version_string[];\n \n-- \n1.4.1\n\n"}]}