From b8e58ff45ece0e46bd2918bc550e70f058ebdd82 Mon Sep 17 00:00:00 2001 From: Luke Howard Date: Tue, 15 Mar 2011 17:14:49 +1100 Subject: [PATCH] plug leak in previous commit --- init_sec_context.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/init_sec_context.c b/init_sec_context.c index a7d17b5..1f445bc 100644 --- a/init_sec_context.c +++ b/init_sec_context.c @@ -952,10 +952,8 @@ gss_init_sec_context(OM_uint32 *minor, if (initialContextToken) { major = initBegin(minor, cred, ctx, target_name, mech_type, req_flags, time_req, input_chan_bindings); - if (GSS_ERROR(major)) { - gssEapReleaseContext(minor, &ctx); - return major; - } + if (GSS_ERROR(major)) + goto cleanup; } major = gssEapSmStep(minor, -- 2.1.4