http_negotiate.c: follow-up for commit 3dcc1a9c

This commit is contained in:
Yang Tse 2013-04-04 12:09:39 +02:00
parent e87e76e2dc
commit ed35e1fa1b
1 changed files with 4 additions and 2 deletions

View File

@ -333,13 +333,15 @@ CURLcode Curl_output_negotiate(struct connectdata *conn, bool proxy)
&encoded, &len);
if(error) {
gss_release_buffer(&discard_st, &neg_ctx->output_token);
neg_ctx->output_token = GSS_C_EMPTY_BUFFER;
neg_ctx->output_token.value = NULL;
neg_ctx->output_token.length = 0;
return error;
}
if(!encoded || !len) {
gss_release_buffer(&discard_st, &neg_ctx->output_token);
neg_ctx->output_token = GSS_C_EMPTY_BUFFER;
neg_ctx->output_token.value = NULL;
neg_ctx->output_token.length = 0;
return CURLE_REMOTE_ACCESS_DENIED;
}