mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-26 17:49:59 -05:00
Plug memory leak
This commit is contained in:
parent
86555712c4
commit
185586f5c2
1 changed files with 3 additions and 0 deletions
|
|
@ -165,6 +165,7 @@ static void openldap_ldap_init_w_conf(const char *file)
|
|||
|
||||
static void openldap_ldap_init_w_userconf(const char *file)
|
||||
{
|
||||
if (file[file[0] == '.'] != '/') {
|
||||
char *home = getenv("HOME");
|
||||
char *path;
|
||||
|
||||
|
|
@ -184,6 +185,8 @@ static void openldap_ldap_init_w_userconf(const char *file)
|
|||
sprintf(path, "%s/.%s", home, file);
|
||||
openldap_ldap_init_w_conf(path);
|
||||
}
|
||||
free(path);
|
||||
}
|
||||
|
||||
/* try file */
|
||||
openldap_ldap_init_w_conf(file);
|
||||
|
|
|
|||
Loading…
Reference in a new issue