aboutsummaryrefslogtreecommitdiff
path: root/ftp/curl
diff options
context:
space:
mode:
authorSunpoet Po-Chuan Hsieh <sunpoet@FreeBSD.org>2013-08-07 03:35:18 +0000
committerSunpoet Po-Chuan Hsieh <sunpoet@FreeBSD.org>2013-08-07 03:35:18 +0000
commit83ce1d58362836cfb803f90c31b7b5838430d022 (patch)
tree8c8e860248df794ee14f4737b94cd696125ac742 /ftp/curl
parentfaff7fe615ad65023ef51addef15f6519ad349c2 (diff)
downloadports-83ce1d58362836cfb803f90c31b7b5838430d022.tar.gz
ports-83ce1d58362836cfb803f90c31b7b5838430d022.zip
Notes
Diffstat (limited to 'ftp/curl')
-rw-r--r--ftp/curl/Makefile1
-rw-r--r--ftp/curl/files/patch-lib-ssluse.c28
2 files changed, 29 insertions, 0 deletions
diff --git a/ftp/curl/Makefile b/ftp/curl/Makefile
index f19fe7b8fb8e..ae265ae5e4ee 100644
--- a/ftp/curl/Makefile
+++ b/ftp/curl/Makefile
@@ -3,6 +3,7 @@
PORTNAME= curl
PORTVERSION= 7.31.0
+PORTREVISION= 1
CATEGORIES= ftp ipv6 www
MASTER_SITES= http://curl.haxx.se/download/ \
LOCAL/sunpoet
diff --git a/ftp/curl/files/patch-lib-ssluse.c b/ftp/curl/files/patch-lib-ssluse.c
new file mode 100644
index 000000000000..7b6d65772865
--- /dev/null
+++ b/ftp/curl/files/patch-lib-ssluse.c
@@ -0,0 +1,28 @@
+--- lib/ssluse.c.orig
++++ lib/ssluse.c
+@@ -2608,13 +2608,19 @@ static ssize_t ossl_recv(struct connectdata *conn, /* connection data */
+ *curlcode = CURLE_AGAIN;
+ return -1;
+ default:
+- /* openssl/ssl.h says "look at error stack/return value/errno" */
++ /* openssl/ssl.h for SSL_ERROR_SYSCALL says "look at error stack/return
++ value/errno" */
++ /* http://www.openssl.org/docs/crypto/ERR_get_error.html */
+ sslerror = ERR_get_error();
+- failf(conn->data, "SSL read: %s, errno %d",
+- ERR_error_string(sslerror, error_buffer),
+- SOCKERRNO);
+- *curlcode = CURLE_RECV_ERROR;
+- return -1;
++ if((nread < 0) || sslerror) {
++ /* If the return code was negative or there actually is an error in the
++ queue */
++ failf(conn->data, "SSL read: %s, errno %d",
++ ERR_error_string(sslerror, error_buffer),
++ SOCKERRNO);
++ *curlcode = CURLE_RECV_ERROR;
++ return -1;
++ }
+ }
+ }
+ return nread;