lib/krb5: acc_resolve_2 leak if ccErrCacheNotFound
Fix the possible leak of 's' allocated by asprintf()
When squashing the changes reference "this fixes an issue introduced by 7bf4d76
("krb5: Improve cccol sub naming; add gss_store_cred_into2()")" in the commit message.
This commit is contained in:
@@ -560,7 +560,8 @@ acc_resolve_2(krb5_context context, krb5_ccache *id, const char *res, const char
|
|||||||
if (error == ccErrCCacheNotFound) {
|
if (error == ccErrCCacheNotFound) {
|
||||||
a->ccache = NULL;
|
a->ccache = NULL;
|
||||||
a->cache_name = NULL;
|
a->cache_name = NULL;
|
||||||
return 0;
|
free(s);
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
if (error == ccNoError)
|
if (error == ccNoError)
|
||||||
error = get_cc_name(a);
|
error = get_cc_name(a);
|
||||||
|
Reference in New Issue
Block a user