1 Fix a memory leak at cleanup-time.
3 diff -up pam_ldap/pam_ldap.c pam_ldap/pam_ldap.c
4 --- pam_ldap/pam_ldap.c 2009-07-22 15:55:42.000000000 -0400
5 +++ pam_ldap/pam_ldap.c 2009-07-22 16:00:23.000000000 -0400
6 @@ -437,6 +437,7 @@ static void
7 _release_config (pam_ldap_config_t ** pconfig)
10 + pam_ssd_t *ssd, *next_ssd;
14 @@ -445,6 +446,9 @@ _release_config (pam_ldap_config_t ** pc
15 if (c->configFile != NULL)
24 @@ -474,6 +478,16 @@ _release_config (pam_ldap_config_t ** pc
29 + while ( ssd != NULL )
31 + next_ssd = ssd->next;
38 if (c->userattr != NULL)
41 @@ -509,6 +523,36 @@ _release_config (pam_ldap_config_t ** pc
45 + if (c->tls_cacertfile != NULL)
47 + free (c->tls_cacertfile);
50 + if (c->tls_cacertdir != NULL)
52 + free (c->tls_cacertdir);
55 + if (c->tls_ciphers != NULL)
57 + free (c->tls_ciphers);
60 + if (c->tls_cert != NULL)
65 + if (c->tls_key != NULL)
70 + if (c->tls_randfile != NULL)
72 + free (c->tls_randfile);
75 if (c->sasl_mechanism != NULL)
77 free (c->sasl_mechanism);