diff options
author | Simo Sorce <ssorce@redhat.com> | 2011-03-24 14:18:54 -0400 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2011-03-28 14:50:59 -0400 |
commit | bb9617f83867590eebef65e906f77094d1088afe (patch) | |
tree | e54b88a81342cdf2b1238fcfae375ac600ae04ff /daemons/ipa-slapi-plugins | |
parent | 446a4ca439820630764f77507682beea7e7ac886 (diff) | |
download | freeipa-bb9617f83867590eebef65e906f77094d1088afe.tar.gz freeipa-bb9617f83867590eebef65e906f77094d1088afe.tar.xz freeipa-bb9617f83867590eebef65e906f77094d1088afe.zip |
Fix resource leaks.
Fixes: https://fedorahosted.org/freeipa/ticket/1119
Diffstat (limited to 'daemons/ipa-slapi-plugins')
-rw-r--r-- | daemons/ipa-slapi-plugins/ipa-pwd-extop/ipapwd_encoding.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/daemons/ipa-slapi-plugins/ipa-pwd-extop/ipapwd_encoding.c b/daemons/ipa-slapi-plugins/ipa-pwd-extop/ipapwd_encoding.c index df1c171a0..1b6bc6f9c 100644 --- a/daemons/ipa-slapi-plugins/ipa-pwd-extop/ipapwd_encoding.c +++ b/daemons/ipa-slapi-plugins/ipa-pwd-extop/ipapwd_encoding.c @@ -603,6 +603,7 @@ static int encode_ntlm_keys(char *newPasswd, /* the lanman password is upper case */ upperPasswd = (char *)slapi_utf8StrToUpper((unsigned char *)newPasswd); if (!upperPasswd) { + iconv_close(cd); ret = -1; goto done; } @@ -614,6 +615,7 @@ static int encode_ntlm_keys(char *newPasswd, asciiPasswd = calloc(ol+1, 1); if (!asciiPasswd) { slapi_ch_free_string(&upperPasswd); + iconv_close(cd); ret = -1; goto done; } |