From a9b4c04f1ca3a64a22c1345c2a7562c1985e14f4 Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Wed, 22 Aug 2007 18:05:18 +0000 Subject: [PATCH] Use MAXHOSTNAMELEN from instead of HOST_NAME_MAX as the latter ain't available here. --- clients/tools/common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clients/tools/common.c b/clients/tools/common.c index 7b4075d0d2..88fe29db48 100644 --- a/clients/tools/common.c +++ b/clients/tools/common.c @@ -1234,7 +1234,7 @@ tool_bind( LDAP *ld ) LDAPControl c; char *ip = NULL, *name = NULL; struct berval id = { 0 }, prefix_id; - char namebuf[ HOST_NAME_MAX ]; + char namebuf[ MAXHOSTNAMELEN ]; char *ptr; if ( gethostname( namebuf, sizeof( namebuf ) ) == 0 ) { @@ -1676,7 +1676,7 @@ tool_server_controls( LDAP *ld, LDAPControl *extra_c, int count ) if ( stValue.bv_val == NULL ) { char *ip = NULL, *name = NULL; struct berval id = { 0 }; - char namebuf[ HOST_NAME_MAX ]; + char namebuf[ MAXHOSTNAMELEN ]; if ( gethostname( namebuf, sizeof( namebuf ) ) == 0 ) { struct hostent *h; -- 2.39.5