]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
SSL_RECV: EOF is not an error here
authorDaniel Stenberg <daniel@haxx.se>
Fri, 16 Apr 2010 13:29:25 +0000 (15:29 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Fri, 16 Apr 2010 13:29:25 +0000 (15:29 +0200)
The recent overhaul of the SSL recv function made this treat a
zero returned from gnutls_record_recv() as an error, and this
caused our HTTPS test cases to fail. We leave it to upper layer
code to detect if an EOF is a problem or not.

lib/gtls.c

index b7fa3c9267354556a2a1ee1e50306b54bc8f9e3f..92d78053049fd03ebae8c3afe53f1cec375bbf48 100644 (file)
@@ -778,12 +778,6 @@ ssize_t Curl_gtls_recv(struct connectdata *conn, /* connection data */
     return -1;
   }
 
-  if(!ret) {
-    failf(conn->data, "Peer closed the TLS connection");
-    *curlcode = CURLE_RECV_ERROR;
-    return -1;
-  }
-
   if(ret < 0) {
     failf(conn->data, "GnuTLS recv error (%d): %s",
           (int)ret, gnutls_strerror((int)ret));