[krbdev.mit.edu #6674] memory leak in SPNEGO
Arlene Berry via RT
rt-comment at krbdev.mit.edu
Fri Mar 5 00:41:21 EST 2010
We caught a memory leak in SPNEGO. This fixed it for us:
Index: src/lib/gssapi/spnego/spnego_mech.c
===================================================================
--- src/lib/gssapi/spnego/spnego_mech.c (revision 23762)
+++ src/lib/gssapi/spnego/spnego_mech.c (working copy)
@@ -1739,9 +1739,12 @@
}
if (ret == GSS_S_COMPLETE) {
*context_handle = (gss_ctx_id_t)sc->ctx_handle;
- if (sc->internal_name != GSS_C_NO_NAME &&
- src_name != NULL) {
+ if (sc->internal_name != GSS_C_NO_NAME) {
+ if (src_name != NULL) {
*src_name = sc->internal_name;
+ } else {
+ gss_release_name(&tmpmin, &sc->internal_name);
+ }
}
release_spnego_ctx(&sc);
} else if (ret != GSS_S_CONTINUE_NEEDED) {
More information about the krb5-bugs
mailing list