]> git.sur5r.net Git - openldap/commitdiff
hostbuf should be static
authorKurt Zeilenga <kurt@openldap.org>
Tue, 15 Aug 2000 00:58:56 +0000 (00:58 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Tue, 15 Aug 2000 00:58:56 +0000 (00:58 +0000)
libraries/libldap/init.c

index 164761b6edfa4254a540a7cc4ecc5bb863b8da05..b8e23caaf2cb5d695b3b257b12eaae0c9a14c68c 100644 (file)
@@ -439,7 +439,7 @@ void ldap_int_initialize( struct ldapoptions *gopts, int *dbglvl )
 #if defined(LDAP_API_FEATURE_X_OPENLDAP_V2_KBIND) \
        || defined(HAVE_TLS) || defined(HAVE_CYRUS_SASL)
        {
-               char hostbuf[MAXHOSTNAMELEN+1];
+               static char hostbuf[MAXHOSTNAMELEN+1];
                if( gethostname( hostbuf, MAXHOSTNAMELEN ) == 0 ) {
                        hostbuf[MAXHOSTNAMELEN] = '\0';
                        ldap_int_hostname = hostbuf;