From 1e488d38c966ec9b8838f5766c88f6092d06a7d8 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Mon, 5 Jul 2021 17:55:24 +0200 Subject: [PATCH] wolfssl: failing to set a session id is not reason to error out ... as it is *probably* just timed out. Reported-by: Francisco Munoz Closes #7358 --- lib/vtls/wolfssl.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/lib/vtls/wolfssl.c b/lib/vtls/wolfssl.c index 8d217ec54..d21c007c1 100644 --- a/lib/vtls/wolfssl.c +++ b/lib/vtls/wolfssl.c @@ -494,15 +494,11 @@ wolfssl_connect_step1(struct Curl_easy *data, struct connectdata *conn, &ssl_sessionid, NULL, sockindex)) { /* we got a session id, use it! */ if(!SSL_set_session(backend->handle, ssl_sessionid)) { - char error_buffer[WOLFSSL_MAX_ERROR_SZ]; - Curl_ssl_sessionid_unlock(data); - failf(data, "SSL: SSL_set_session failed: %s", - ERR_error_string(SSL_get_error(backend->handle, 0), - error_buffer)); - return CURLE_SSL_CONNECT_ERROR; + Curl_ssl_delsessionid(data, ssl_sessionid); + infof(data, "Can't use session ID, going on without\n"); } - /* Informational message */ - infof(data, "SSL re-using session ID\n"); + else + infof(data, "SSL re-using session ID\n"); } Curl_ssl_sessionid_unlock(data); }