diff --git a/lib/vtls/vtls.c b/lib/vtls/vtls.c index 22d820b160..df0449cbee 100644 --- a/lib/vtls/vtls.c +++ b/lib/vtls/vtls.c @@ -1858,7 +1858,8 @@ static CURLcode vtls_shutdown_blocking(struct Curl_cfilter *cf, if(timeout_ms < 0) { /* no need to continue if time is already up */ failf(data, "SSL shutdown timeout"); - return CURLE_OPERATION_TIMEDOUT; + result = CURLE_OPERATION_TIMEDOUT; + goto out; } result = connssl->ssl_impl->shut_down(cf, data, send_shutdown, done);