From 0afbcfd800c45e766e225e4ce273b128ee6a8c25 Mon Sep 17 00:00:00 2001 From: Michael Kaufmann Date: Sat, 11 Mar 2017 18:22:30 +0100 Subject: [PATCH] curl_easy_reset: Also reset the authentication state Follow-up to 5278462 See https://github.com/curl/curl/issues/1095 --- lib/easy.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/easy.c b/lib/easy.c index bed94a444..ef023aa92 100644 --- a/lib/easy.c +++ b/lib/easy.c @@ -981,6 +981,10 @@ void curl_easy_reset(struct Curl_easy *data) data->progress.flags |= PGRS_HIDE; data->state.current_speed = -1; /* init to negative == impossible */ + + /* zero out authentication data: */ + memset(&data->state.authhost, 0, sizeof(struct auth)); + memset(&data->state.authproxy, 0, sizeof(struct auth)); } /*