Skip to content

Commit

Permalink
sasl_gssapi: Fixed memory leak with local SPN variable
Browse files Browse the repository at this point in the history
  • Loading branch information
captain-caveman2k committed Jan 18, 2015
1 parent 3a9419f commit b9fd757
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/curl_sasl_gssapi.c
Expand Up @@ -122,8 +122,12 @@ CURLcode Curl_sasl_create_gssapi_user_message(struct SessionHandle *data,
if(GSS_ERROR(gss_major_status)) {
Curl_gss_log_error(data, gss_minor_status, "gss_import_name() failed: ");

Curl_safefree(spn);

return CURLE_OUT_OF_MEMORY;
}

Curl_safefree(spn);
}
else {
/* Decode the base-64 encoded challenge message */
Expand Down

0 comments on commit b9fd757

Please sign in to comment.