aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/ssluse.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/ssluse.c b/lib/ssluse.c
index d0eaadede..d8f776018 100644
--- a/lib/ssluse.c
+++ b/lib/ssluse.c
@@ -2371,6 +2371,12 @@ ossl_connect_common(struct connectdata *conn,
long timeout_ms;
int what;
+ /* check if the connection has already been established */
+ if(ssl_connection_complete == connssl->state) {
+ *done = TRUE;
+ return CURLE_OK;
+ }
+
if(ssl_connect_1==connssl->connecting_state) {
/* Find out how much more time we're allowed */
timeout_ms = Curl_timeleft(conn, NULL, TRUE);