Fix a KDC memory leak that was introduced by r23724 that could leak
the decoded request.
ticket: 6711
tags: pullup
target_version: 1.8.2
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@23959
dc483132-0cff-0310-8789-
dd5450dbe970
retval = decode_krb5_tgs_req(pkt, &request);
if (retval)
return retval;
- if (request->msg_type != KRB5_TGS_REQ)
+ if (request->msg_type != KRB5_TGS_REQ) {
+ krb5_free_kdc_req(kdc_context, request);
return KRB5_BADMSGTYPE;
+ }
/*
* setup_server_realm() sets up the global realm-specific data pointer.