From 51749e5e6d3256f071634f150d0393adce8d5629 Mon Sep 17 00:00:00 2001 From: Greg Hudson Date: Wed, 6 May 2009 15:56:21 +0000 Subject: [PATCH] Fix a memory leak in pa_sam_2 where an outer data structure wasn't freed after the contents are coopted. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22318 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/krb/preauth2.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/lib/krb5/krb/preauth2.c b/src/lib/krb5/krb/preauth2.c index d00d59b9d..693791f85 100644 --- a/src/lib/krb5/krb/preauth2.c +++ b/src/lib/krb5/krb/preauth2.c @@ -1705,6 +1705,7 @@ krb5_error_code pa_sam_2(krb5_context context, sam_padata->pa_type = KRB5_PADATA_SAM_RESPONSE_2; sam_padata->length = scratch->length; sam_padata->contents = (krb5_octet *) scratch->data; + free(scratch); *out_padata = sam_padata; -- 2.26.2