diff options
author | Marcus Alves Grando <mnag@FreeBSD.org> | 2008-04-19 14:17:54 +0000 |
---|---|---|
committer | Marcus Alves Grando <mnag@FreeBSD.org> | 2008-04-19 14:17:54 +0000 |
commit | bf8618d65065357e13920ee2298f2beb03544eea (patch) | |
tree | 06a42de42c9d67c8921c902463f3f8aca98425b1 /www/pecl-APC | |
parent | 061f2c543ffbd7ac2e9391c1cb26bc8ccd30a788 (diff) | |
download | ports-bf8618d65065357e13920ee2298f2beb03544eea.tar.gz ports-bf8618d65065357e13920ee2298f2beb03544eea.zip |
Notes
Diffstat (limited to 'www/pecl-APC')
-rw-r--r-- | www/pecl-APC/Makefile | 1 | ||||
-rw-r--r-- | www/pecl-APC/files/patch-apc_main.c | 30 |
2 files changed, 31 insertions, 0 deletions
diff --git a/www/pecl-APC/Makefile b/www/pecl-APC/Makefile index 509e33df2e28..5c54df540f9a 100644 --- a/www/pecl-APC/Makefile +++ b/www/pecl-APC/Makefile @@ -7,6 +7,7 @@ PORTNAME= APC DISTVERSION= 3.0.18 +PORTREVISION= 1 CATEGORIES= www MASTER_SITES= http://pecl.php.net/get/ PKGNAMEPREFIX= pecl- diff --git a/www/pecl-APC/files/patch-apc_main.c b/www/pecl-APC/files/patch-apc_main.c new file mode 100644 index 000000000000..1c468911909b --- /dev/null +++ b/www/pecl-APC/files/patch-apc_main.c @@ -0,0 +1,30 @@ +# +# Fix FD leak to PHP4 (from pecl-APC CVS) +# +--- apc_main.c 2008/03/29 06:38:40 3.103.2.3 ++++ apc_main.c 2008/03/31 14:14:12 3.103.2.4 +@@ -279,7 +279,11 @@ + apc_cache_release(apc_cache, cache_entry); + + /* cannot free up cache data yet, it maybe in use */ +- ++ ++#ifndef ZEND_ENGINE_2 ++ zend_llist_del_element(&CG(open_files), h, compare_file_handles); /* We leak fds in PHP 4 without this hack */ ++#endif ++ + h->type = ZEND_HANDLE_FILENAME; + + return NULL; +@@ -351,6 +355,11 @@ + reset_opened_path = 1; + } + zend_hash_add(&EG(included_files), h->opened_path, strlen(h->opened_path)+1, (void *)&dummy, sizeof(int), NULL); ++ ++#ifndef ZEND_ENGINE_2 ++ zend_llist_add_element(&CG(open_files), h); /* We leak fds in PHP 4 without this hack */ ++#endif ++ + apc_stack_push(APCG(cache_stack), cache_entry); + op_array = cached_compile(h, type TSRMLS_CC); + if(op_array) { |