summaryrefslogtreecommitdiff
path: root/ext/openssl
diff options
context:
space:
mode:
authorAntony Dovgal <tony2001@php.net>2008-07-11 10:25:15 +0000
committerAntony Dovgal <tony2001@php.net>2008-07-11 10:25:15 +0000
commitcf7e15c3a0fb44f57298c1761a373ca08a6d4a9d (patch)
tree01f29a896bb67c620cb1a02d1ea28506c71c34a4 /ext/openssl
parent46f41aded18fe844e00385fb670a321bf2a75837 (diff)
downloadphp-git-cf7e15c3a0fb44f57298c1761a373ca08a6d4a9d.tar.gz
MFH: manage references of stream context properly
Diffstat (limited to 'ext/openssl')
-rw-r--r--ext/openssl/xp_ssl.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c
index d1d97940bf..3beefb6d23 100644
--- a/ext/openssl/xp_ssl.c
+++ b/ext/openssl/xp_ssl.c
@@ -556,7 +556,9 @@ static inline int php_openssl_tcp_sockop_accept(php_stream *stream, php_openssl_
xparam->outputs.client = php_stream_alloc_rel(stream->ops, clisockdata, NULL, "r+");
if (xparam->outputs.client) {
- xparam->outputs.client->context = stream->context;
+ if (stream->context) {
+ zend_list_addref(stream->context->rsrc_id);
+ }
}
}