summaryrefslogtreecommitdiffstats
path: root/source4/lib/replace/replace.h
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2007-09-08 01:39:31 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 15:05:37 -0500
commitd0f3d4a2f1c674f6b07b6ec4640a2c8d033bad2a (patch)
tree80e5b3e365cb58ba03da557136585a31c67c33f4 /source4/lib/replace/replace.h
parentb9c829b7d9d70fd8dcb890db9d7e35c7ab216fcf (diff)
downloadsamba-d0f3d4a2f1c674f6b07b6ec4640a2c8d033bad2a.tar.gz
samba-d0f3d4a2f1c674f6b07b6ec4640a2c8d033bad2a.tar.xz
samba-d0f3d4a2f1c674f6b07b6ec4640a2c8d033bad2a.zip
r25017: Move MAXHOSTNAMELEN definition to replace.h as it is usually part of
sys/param.h. (This used to be commit 7016d500287ae587d044744f2a318c402148ebea)
Diffstat (limited to 'source4/lib/replace/replace.h')
-rw-r--r--source4/lib/replace/replace.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/source4/lib/replace/replace.h b/source4/lib/replace/replace.h
index 06173bd84b..052c7346a3 100644
--- a/source4/lib/replace/replace.h
+++ b/source4/lib/replace/replace.h
@@ -375,6 +375,14 @@ ssize_t rep_pwrite(int __fd, const void *__buf, size_t __nbytes, off_t __offset)
#define HOST_NAME_MAX 64
#endif
+/*
+ * Some older systems seem not to have MAXHOSTNAMELEN
+ * defined.
+ */
+#ifndef MAXHOSTNAMELEN
+#define MAXHOSTNAMELEN HOST_NAME_MAX
+#endif
+
#ifndef UINT16_MAX
#define UINT16_MAX 65535
#endif