]> git.sur5r.net Git - openldap/commitdiff
Fix possible under allocation of buffer
authorKurt Zeilenga <kurt@openldap.org>
Mon, 8 Jul 2002 18:45:53 +0000 (18:45 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Mon, 8 Jul 2002 18:45:53 +0000 (18:45 +0000)
libraries/libldap/dnssrv.c

index cc193e93582bef587dcfb15c511b60feaf00d18d..0f7c863b2bcd34f288833c25e2d8b0bf8c655f44 100644 (file)
@@ -261,7 +261,7 @@ int ldap_domain2hostlist(
                /* weight = (p[2] << 8) | p[3]; */
                port = (p[4] << 8) | p[5];
 
-               buflen = strlen(host) + sizeof(":65355");
+               buflen = strlen(host) + sizeof(":65355 ");
                hostlist = (char *) LDAP_REALLOC(hostlist, cur + buflen);
                if (hostlist == NULL) {
                    rc = LDAP_NO_MEMORY;