From: Tom Yu Date: Fri, 30 Apr 2010 21:10:55 +0000 (+0000) Subject: memory leak in process_tgs_req in r23724 X-Git-Tag: krb5-1.9-beta1~258 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=d20d802b8e44178017fd1a1da55a72194f50da55;p=krb5.git memory leak in process_tgs_req in r23724 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 --- diff --git a/src/kdc/do_tgs_req.c b/src/kdc/do_tgs_req.c index 76ca94abc..29546bd25 100644 --- a/src/kdc/do_tgs_req.c +++ b/src/kdc/do_tgs_req.c @@ -144,8 +144,10 @@ process_tgs_req(krb5_data *pkt, const krb5_fulladdr *from, 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.