[784] in Kerberos-V5-bugs
Re: gssapi accept_sec_context calls free() twice.
daemon@ATHENA.MIT.EDU (Theodore Ts'o)
Tue Sep 27 23:30:14 1994
Date: Tue, 27 Sep 1994 23:30:10 +0500
From: Theodore Ts'o <tytso@MIT.EDU>
To: John Gardiner Myers <jgm+@CMU.EDU>
Cc: jik@gza.com, bjaspan@gza.com
Cc: krb5-bugs@MIT.EDU
In-Reply-To: [778]
Oops... sorry, I spoke too soon. The bug that we had already fixed was
another such bug that we had already fixed. :-)
Anyway, I've applied your suggested fix to our patches, and the
following change will appear in our upcoming release.
(People in Openvision, please take note of this change; it arises from a
change in how krb5_rc_dfl_close() works starting in Beta 4 --- it now
frees the rcache structure, which makes since since it was the rcache
routines that originally allocated it.)
- Ted
--- accept_sec_context.c 1994/08/18 21:56:46 1.4
+++ accept_sec_context.c 1994/09/28 03:26:03
@@ -222,7 +222,6 @@
if (code = krb5_rd_req(&ap_req, cred->princ, paddr, NULL, &rd_req_keyproc,
(krb5_pointer) cred->keytab, rcache, &authdat)) {
(void) krb5_rc_close(rcache);
- xfree(rcache);
*minor_status = code;
return(GSS_S_FAILURE);
}
@@ -230,7 +229,6 @@
/* close and free the rcache */
krb5_rc_close(rcache);
- xfree(rcache);
/* make sure the necessary parts of the authdat are present */