aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2003-10-19 17:38:51 +0000
committerDaniel Stenberg <daniel@haxx.se>2003-10-19 17:38:51 +0000
commitd9f961ed2d5313c45fb8272c338a7dd2937a68b6 (patch)
treea4e818926d4a50aec9d62fcc1a45e483ff7a5bd9 /lib
parentc7f54764163fe9e3ba042b179e6398ccdc8e34ad (diff)
better error output on SSL errors when receiving data - Georg Horn patch
Diffstat (limited to 'lib')
-rw-r--r--lib/sendf.c21
1 files changed, 9 insertions, 12 deletions
diff --git a/lib/sendf.c b/lib/sendf.c
index 76e01393e..41f309236 100644
--- a/lib/sendf.c
+++ b/lib/sendf.c
@@ -383,19 +383,16 @@ int Curl_read(struct connectdata *conn,
case SSL_ERROR_WANT_WRITE:
/* there's data pending, re-invoke SSL_read() */
return -1; /* basicly EWOULDBLOCK */
- case SSL_ERROR_SYSCALL:
- /* openssl/ssl.h says "look at error stack/return value/errno" */
- {
- char error_buffer[120]; /* OpenSSL documents that this must be at least
- 120 bytes long. */
- int sslerror = ERR_get_error();
- failf(conn->data, "SSL read: %s, errno %d",
- ERR_error_string(sslerror, error_buffer),
- Curl_ourerrno() );
- }
- return CURLE_RECV_ERROR;
default:
- failf(conn->data, "SSL read error: %d", err);
+ /* openssl/ssl.h says "look at error stack/return value/errno" */
+ {
+ char error_buffer[120]; /* OpenSSL documents that this must be at
+ least 120 bytes long. */
+ int sslerror = ERR_get_error();
+ failf(conn->data, "SSL read: %s, errno %d",
+ ERR_error_string(sslerror, error_buffer),
+ Curl_ourerrno() );
+ }
return CURLE_RECV_ERROR;
}
}