mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-22 07:39:35 -05:00
make sure cred is freed
This commit is contained in:
parent
cef31a77a7
commit
9f8adeb289
1 changed files with 2 additions and 1 deletions
|
|
@ -299,7 +299,7 @@ main( int argc, char *argv[] )
|
||||||
dn = argv[optind++];
|
dn = argv[optind++];
|
||||||
}
|
}
|
||||||
if (argc - optind > 0) {
|
if (argc - optind > 0) {
|
||||||
cred.bv_val = argv[optind++];
|
cred.bv_val = strdup(argv[optind++]);
|
||||||
cred.bv_len = strlen(cred.bv_val);
|
cred.bv_len = strlen(cred.bv_val);
|
||||||
}
|
}
|
||||||
if (argc - optind > 0) {
|
if (argc - optind > 0) {
|
||||||
|
|
@ -501,6 +501,7 @@ skip:
|
||||||
ber_bvfree( scookie );
|
ber_bvfree( scookie );
|
||||||
ber_bvfree( scred );
|
ber_bvfree( scred );
|
||||||
ber_memfree( diag );
|
ber_memfree( diag );
|
||||||
|
free( cred.bv_val );
|
||||||
|
|
||||||
/* disconnect from server */
|
/* disconnect from server */
|
||||||
tool_unbind( ld );
|
tool_unbind( ld );
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue