com php-src: Release ssl buffers: ext/openssl/xp_ssl.c
| From: | rdlowrey@php.net | Date: | Fri, 21 Feb 2014 00:10:06 +0000 |
| Subject: | com php-src: Release ssl buffers: ext/openssl/xp_ssl.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-76148@lists.php.net to get a copy of this message | ||
Commit: b9ba011c0f2b147bd5b0faba04a6ef7aabaa48c4
Author: Daniel Lowrey <rdlowrey@php.net> Tue, 11 Feb 2014 06:24:34 -0700
Parents: df6bfe3be209ba89a5d8a5f045f09a90db9dc16d
Branches: PHP-5.6
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=b9ba011c0f2b147bd5b0faba04a6ef7aabaa48c4
Log:
Release ssl buffers
Changed paths:
M ext/openssl/xp_ssl.c
Diff:
diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c
index 198dda3..4dda5a4 100644
--- a/ext/openssl/xp_ssl.c
+++ b/ext/openssl/xp_ssl.c
@@ -435,6 +435,11 @@ static inline int php_openssl_setup_crypto(php_stream *stream,
return -1;
}
+#ifdef SSL_MODE_RELEASE_BUFFERS
+ long mode = SSL_get_mode(sslsock->ssl_handle);
+ SSL_set_mode(sslsock->ssl_handle, mode | SSL_MODE_RELEASE_BUFFERS);
+#endif
+
if (!SSL_set_fd(sslsock->ssl_handle, sslsock->s.socket)) {
handle_ssl_error(stream, 0, 1 TSRMLS_CC);
}