]> git.sur5r.net Git - openldap/commitdiff
malloc cleanup
authorJong Hyuk Choi <jongchoi@openldap.org>
Fri, 8 Apr 2005 19:39:58 +0000 (19:39 +0000)
committerJong Hyuk Choi <jongchoi@openldap.org>
Fri, 8 Apr 2005 19:39:58 +0000 (19:39 +0000)
servers/slapd/back-bdb/config.c

index 785bd7e3da6478dca8145894ce8f20925d2441e5..e21d6062b56f79ee5f2417c20aacb3ba7e809465 100644 (file)
@@ -263,7 +263,7 @@ bdb_cf_gen(ConfigArgs *c)
 
                /* See if a DB_CONFIG file already exists here */
                bdb->bi_db_config_path = ch_malloc( strlen( bdb->bi_dbenv_home ) +
-                       STRLENOF(LDAP_DIRSEP) + STRLENOF("DB_CONFIG"));
+                       STRLENOF(LDAP_DIRSEP) + STRLENOF("DB_CONFIG") + 1 );
                ptr = lutil_strcopy( bdb->bi_db_config_path, bdb->bi_dbenv_home );
                *ptr++ = LDAP_DIRSEP[0];
                strcpy( ptr, "DB_CONFIG" );