summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authormichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-01-14 17:37:55 +0000
committermichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-01-14 17:37:55 +0000
commitfa3b6b6c9ca3240366e6ec985d339a07681cd9c6 (patch)
tree7c3dfd18b7ec6a2de047d7ac82aef2057bfc3b48 /include
parent33862809dfc9df2bf039dfbf47f7524c00947b54 (diff)
- Quick and dirty workaround to fix build on GNU/Hurd
because of undefined PATH_MAX git-svn-id: svn://svn.ircd-hybrid.org/svnroot/ircd-hybrid/trunk@1737 82007160-df01-0410-b94d-b575c5fd34c7
Diffstat (limited to 'include')
-rw-r--r--include/conf_db.h4
-rw-r--r--include/modules.h2
-rw-r--r--include/motd.h2
-rw-r--r--include/stdinc.h6
4 files changed, 10 insertions, 4 deletions
diff --git a/include/conf_db.h b/include/conf_db.h
index 7cdc555..de9d00a 100644
--- a/include/conf_db.h
+++ b/include/conf_db.h
@@ -32,8 +32,8 @@ struct dbFILE
{
char mode; /**< 'r' for reading, 'w' for writing */
FILE *fp; /**< The file pointer itself */
- char filename[PATH_MAX + 1]; /**< Name of the database file */
- char tempname[PATH_MAX + 1]; /**< Name of the temporary file (for writing) */
+ char filename[HYB_PATH_MAX + 1]; /**< Name of the database file */
+ char tempname[HYB_PATH_MAX + 1]; /**< Name of the temporary file (for writing) */
};
extern void check_file_version(struct dbFILE *);
diff --git a/include/modules.h b/include/modules.h
index f96d544..3975b84 100644
--- a/include/modules.h
+++ b/include/modules.h
@@ -45,7 +45,7 @@ struct module
struct module_path
{
dlink_node node;
- char path[PATH_MAX + 1];
+ char path[HYB_PATH_MAX + 1];
};
extern dlink_list modules_list;
diff --git a/include/motd.h b/include/motd.h
index 24e15e6..4490b17 100644
--- a/include/motd.h
+++ b/include/motd.h
@@ -47,7 +47,7 @@ struct MessageFile
{
MessageFileLine *contentsOfFile;
MotdType motdType;
- char fileName[PATH_MAX + 1];
+ char fileName[HYB_PATH_MAX + 1];
char lastChangedDate[MAX_DATE_STRING + 1];
};
diff --git a/include/stdinc.h b/include/stdinc.h
index 09c0939..288f4da 100644
--- a/include/stdinc.h
+++ b/include/stdinc.h
@@ -87,4 +87,10 @@
#include <sys/param.h>
#endif
+#ifdef PATH_MAX
+#define HYB_PATH_MAX PATH_MAX
+#else
+#define HYB_PATH_MAX 4096
+#endif
+
#endif