com php-src: Merge https://github.com/bbroerman30/php-src into windows-ssl-timeout-fix: ext/openssl/xp_ssl.c
| From: | rdlowrey@php.net | Date: | Tue, 27 Jan 2015 18:22:47 +0000 |
| Subject: | com php-src: Merge https://github.com/bbroerman30/php-src into windows-ssl-timeout-fix: ext/openssl/xp_ssl.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-84404@lists.php.net to get a copy of this message | ||
Commit: 4965fe7fb8c0fdc8a666bee37f46cad329fefe1f
Author: Daniel Lowrey <rdlowrey@php.net> Tue, 27 Jan 2015 13:22:47 -0500
Parents: 95142d901568963b3f9d0cf0d9782021bd83f35f 8302d658db17a8314b0e2f9c71e536ec42fd2dcd
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=4965fe7fb8c0fdc8a666bee37f46cad329fefe1f
Log:
Merge https://github.com/bbroerman30/php-src
into windows-ssl-timeout-fix
Conflicts:
ext/openssl/xp_ssl.c
Changed paths:
MM ext/openssl/xp_ssl.c
Diff:
diff --cc ext/openssl/xp_ssl.c
index 0b83fb1,0223d0a..fb37b03
--- a/ext/openssl/xp_ssl.c
+++ b/ext/openssl/xp_ssl.c
@@@ -1827,12 -1827,15 +1827,15 @@@ static size_t php_openssl_sockop_io(in
/* Get the error code from SSL, and check to see if it's an error or not. */
int err = SSL_get_error(sslsock->ssl_handle, nr_bytes );
retry = handle_ssl_error(stream, nr_bytes, 0);
-
+
/* If we get this (the above doesn't check) then we'll retry as well. */
- if (errno == EAGAIN && ( err == SSL_ERROR_WANT_READ || SSL_ERROR_WANT_WRITE ) ) {
- if (errno == EAGAIN && err == SSL_ERROR_WANT_READ && read) {
++ if (errno == EAGAIN && err == SSL_ERROR_WANT_READ && read) {
retry = 1;
}
-
+ if (errno == EAGAIN && SSL_ERROR_WANT_WRITE && read == 0) {
+ retry = 1;
+ }
+
/* Also, on reads, we may get this condition on an EOF. We should check properly. */
if (read) {
stream->eof = (retry == 0 && errno != EAGAIN &&
!SSL_pending(sslsock->ssl_handle));