Re: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c
Hi! Why? I'm not aware of any dl()-related problems in FastCGI. FastCGI is like all other long-running SAPIs, so can't it have the same problems httpd has? -- Stanislav Malyshev, Zend Software Architect s...@zend.com http://www.zend.com/ (408)253-8829 MSN: s...@zend.com -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c
Why? I'm not aware of any dl()-related problems in FastCGI. FastCGI is like all other long-running SAPIs, so can't it have the same problems httpd has? OK that's confused me... I thought the problem with dl() was purely in threaded SAPIs? - otherwise surely it should've been dropped for CLI forever ago? What did I miss? - Steph ps Happy new year Stas ;) -- Stanislav Malyshev, Zend Software Architect s...@zend.com http://www.zend.com/ (408)253-8829 MSN: s...@zend.com -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c
On 02.01.2009 07:47, Andi Gutmans wrote: Hi Marcus, I think dl() should also be disabled for FastCGI. Why? I'm not aware of any dl()-related problems in FastCGI. -- Wbr, Antony Dovgal -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c
Hello Andi, my main goal was to get rid of dl() for apache and alike modules and get the c level API changes in. For FastCGI I guess you are right, but I would appreciate if Dmitry could look into it. As far as I understand the only thing we have to do is to pass the function table containing the dl() only if we are not in FastCGI mode. So basically if ther is no -b command line flag. marcus Friday, January 2, 2009, 5:47:09 AM, you wrote: Hi Marcus, I think dl() should also be disabled for FastCGI. It may require a bit of reordering of the code to make this work but I think it's the right thing. If you bump into any problems then maybe Dmitry could help out but he's on vacation for the next couple of weeks. Thanks! Andi -Original Message- From: Marcus Boerger [mailto:he...@php.net] Sent: Wednesday, December 31, 2008 6:27 AM To: php-cvs@lists.php.net; php...@lists.php.net Subject: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c helly Wed Dec 31 14:27:10 2008 UTC Modified files: (Branch: PHP_5_3) /php-srcNEWS /php-src/ext/standard basic_functions.c /php-src/main SAPI.h main.c /php-src/sapi/cgi cgi_main.c /php-src/sapi/cli php_cli.c /php-src/sapi/embed php_embed.c Log: MFH - Changed dl() to be disabled by default. Enabled only when explicitly registered by the SAPI layer. Enabled only with CLI, CGI and EMBED. (Dmitry) [DOC] http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.428r 2=1.2027.2.547.2.965.2.429diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.2027.2.547.2.965.2.428 php-src/NEWS:1.2027.2.547.2.965.2.429 --- php-src/NEWS:1.2027.2.547.2.965.2.428 Tue Dec 30 23:34:29 2008 +++ php-src/NEWSWed Dec 31 14:27:08 2008 @@ -6,6 +6,8 @@ - Deprecated session_register(), session_unregister() and session_is_registered(). (Hannes) +- Changed dl() to be disabled by default. Enabled only when explicitly + registered by the SAPI layer. Enabled only with CLI, CGI and EMBED. (Dmitry) - Changed opendir(), dir() and scandir() to use default context when no context argument is passed. (Sara) - Changed open_basedir to allow tightening in runtime contexts. (Sara) http://cvs.php.net/viewvc.cgi/php-src/ext/standard/basic_functions.c?r1= 1.725.2.31.2.64.2.79r2=1.725.2.31.2.64.2.80diff_format=u Index: php-src/ext/standard/basic_functions.c diff -u php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.79 php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.80 --- php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.79 Wed Dec 31 11:15:44 2008 +++ php-src/ext/standard/basic_functions.c Wed Dec 31 14:27:09 2008 @@ -18,7 +18,7 @@ +--+ */ -/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.79 2008/12/31 11:15:44 sebastian Exp $ */ +/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.80 2008/12/31 14:27:09 helly Exp $ */ #include php.h #include php_streams.h @@ -3025,9 +3025,6 @@ PHP_FE(is_scalar, arginfo_is_scalar) PHP_FE(is_callable, arginfo_is_callable) - /* functions from dl.c */ - PHP_FE(dl, arginfo_dl) - /* functions from file.c */ PHP_FE(pclose, arginfo_pclose) PHP_FE(popen, arginfo_popen) http://cvs.php.net/viewvc.cgi/php-src/main/SAPI.h?r1=1.114.2.1.2.3.2.5r 2=1.114.2.1.2.3.2.6diff_format=u Index: php-src/main/SAPI.h diff -u php-src/main/SAPI.h:1.114.2.1.2.3.2.5 php-src/main/SAPI.h:1.114.2.1.2.3.2.6 --- php-src/main/SAPI.h:1.114.2.1.2.3.2.5 Wed Dec 31 11:15:47 2008 +++ php-src/main/SAPI.h Wed Dec 31 14:27:09 2008 @@ -16,7 +16,7 @@ +--+ */ -/* $Id: SAPI.h,v 1.114.2.1.2.3.2.5 2008/12/31 11:15:47 sebastian Exp $ */ +/* $Id: SAPI.h,v 1.114.2.1.2.3.2.6 2008/12/31 14:27:09 helly Exp $ */ #ifndef SAPI_H #define SAPI_H @@ -264,6 +264,7 @@ int phpinfo_as_text; char *ini_entries; + const zend_function_entry *additional_functions; }; http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.640.2.23.2.57.2.4 0r2=1.640.2.23.2.57.2.41diff_format=u Index: php-src/main/main.c diff -u php-src/main/main.c:1.640.2.23.2.57.2.40 php-src/main/main.c:1.640.2.23.2.57.2.41 --- php-src/main/main.c:1.640.2.23.2.57.2.40Wed Dec 31 14:05:22 2008 +++ php-src/main/main.c Wed Dec 31 14:27:09 2008 @@ -18,7 +18,7 @@ +--+ */ -/* $Id: main.c,v 1.640.2.23.2.57.2.40 2008/12/31 14:05:22 helly Exp $ */ +/* $Id: main.c,v 1.640.2.23.2.57.2.41 2008/12/31 14:27:09 helly Exp $ */ /* {{{ includes */ @@ -1910,6 +1910,15 @@
RE: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c
Ok will ask him to take a look when he's back. Cheers, Andi -Original Message- From: Marcus Boerger [mailto:he...@php.net] Sent: Friday, January 02, 2009 4:04 AM To: Andi Gutmans Cc: Marcus Boerger; php-cvs@lists.php.net Subject: Re: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c Hello Andi, my main goal was to get rid of dl() for apache and alike modules and get the c level API changes in. For FastCGI I guess you are right, but I would appreciate if Dmitry could look into it. As far as I understand the only thing we have to do is to pass the function table containing the dl() only if we are not in FastCGI mode. So basically if ther is no -b command line flag. marcus Friday, January 2, 2009, 5:47:09 AM, you wrote: Hi Marcus, I think dl() should also be disabled for FastCGI. It may require a bit of reordering of the code to make this work but I think it's the right thing. If you bump into any problems then maybe Dmitry could help out but he's on vacation for the next couple of weeks. Thanks! Andi -Original Message- From: Marcus Boerger [mailto:he...@php.net] Sent: Wednesday, December 31, 2008 6:27 AM To: php-cvs@lists.php.net; php...@lists.php.net Subject: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c helly Wed Dec 31 14:27:10 2008 UTC Modified files: (Branch: PHP_5_3) /php-srcNEWS /php-src/ext/standard basic_functions.c /php-src/main SAPI.h main.c /php-src/sapi/cgi cgi_main.c /php-src/sapi/cli php_cli.c /php-src/sapi/embed php_embed.c Log: MFH - Changed dl() to be disabled by default. Enabled only when explicitly registered by the SAPI layer. Enabled only with CLI, CGI and EMBED. (Dmitry) [DOC] http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.428r 2=1.2027.2.547.2.965.2.429diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.2027.2.547.2.965.2.428 php-src/NEWS:1.2027.2.547.2.965.2.429 --- php-src/NEWS:1.2027.2.547.2.965.2.428 Tue Dec 30 23:34:29 2008 +++ php-src/NEWSWed Dec 31 14:27:08 2008 @@ -6,6 +6,8 @@ - Deprecated session_register(), session_unregister() and session_is_registered(). (Hannes) +- Changed dl() to be disabled by default. Enabled only when explicitly + registered by the SAPI layer. Enabled only with CLI, CGI and EMBED. (Dmitry) - Changed opendir(), dir() and scandir() to use default context when no context argument is passed. (Sara) - Changed open_basedir to allow tightening in runtime contexts. (Sara) http://cvs.php.net/viewvc.cgi/php-src/ext/standard/basic_functions.c?r1= 1.725.2.31.2.64.2.79r2=1.725.2.31.2.64.2.80diff_format=u Index: php-src/ext/standard/basic_functions.c diff -u php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.79 php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.80 --- php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.79 Wed Dec 31 11:15:44 2008 +++ php-src/ext/standard/basic_functions.c Wed Dec 31 14:27:09 2008 @@ -18,7 +18,7 @@ +--+ */ -/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.79 2008/12/31 11:15:44 sebastian Exp $ */ +/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.80 2008/12/31 14:27:09 helly Exp $ */ #include php.h #include php_streams.h @@ -3025,9 +3025,6 @@ PHP_FE(is_scalar, arginfo_is_scalar) PHP_FE(is_callable, arginfo_is_callable) - /* functions from dl.c */ - PHP_FE(dl, arginfo_dl) - /* functions from file.c */ PHP_FE(pclose, arginfo_pclose) PHP_FE(popen, arginfo_popen) http://cvs.php.net/viewvc.cgi/php-src/main/SAPI.h?r1=1.114.2.1.2.3.2.5r 2=1.114.2.1.2.3.2.6diff_format=u Index: php-src/main/SAPI.h diff -u php-src/main/SAPI.h:1.114.2.1.2.3.2.5 php-src/main/SAPI.h:1.114.2.1.2.3.2.6 --- php-src/main/SAPI.h:1.114.2.1.2.3.2.5 Wed Dec 31 11:15:47 2008 +++ php-src/main/SAPI.h Wed Dec 31 14:27:09 2008 @@ -16,7 +16,7 @@ +--+ */ -/* $Id: SAPI.h,v 1.114.2.1.2.3.2.5 2008/12/31 11:15:47 sebastian Exp $ */ +/* $Id: SAPI.h,v 1.114.2.1.2.3.2.6 2008/12/31 14:27:09 helly Exp $ */ #ifndef SAPI_H #define SAPI_H @@ -264,6 +264,7 @@ int phpinfo_as_text; char *ini_entries; + const zend_function_entry *additional_functions; }; http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.640.2.23.2.57.2.4 0r2=1.640.2.23.2.57.2.41diff_format=u Index: php-src/main/main.c diff -u php-src/main/main.c
RE: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c
Hi Marcus, I think dl() should also be disabled for FastCGI. It may require a bit of reordering of the code to make this work but I think it's the right thing. If you bump into any problems then maybe Dmitry could help out but he's on vacation for the next couple of weeks. Thanks! Andi -Original Message- From: Marcus Boerger [mailto:he...@php.net] Sent: Wednesday, December 31, 2008 6:27 AM To: php-cvs@lists.php.net; php...@lists.php.net Subject: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c helly Wed Dec 31 14:27:10 2008 UTC Modified files: (Branch: PHP_5_3) /php-srcNEWS /php-src/ext/standard basic_functions.c /php-src/main SAPI.h main.c /php-src/sapi/cgi cgi_main.c /php-src/sapi/cli php_cli.c /php-src/sapi/embed php_embed.c Log: MFH - Changed dl() to be disabled by default. Enabled only when explicitly registered by the SAPI layer. Enabled only with CLI, CGI and EMBED. (Dmitry) [DOC] http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.965.2.428r 2=1.2027.2.547.2.965.2.429diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.2027.2.547.2.965.2.428 php-src/NEWS:1.2027.2.547.2.965.2.429 --- php-src/NEWS:1.2027.2.547.2.965.2.428 Tue Dec 30 23:34:29 2008 +++ php-src/NEWSWed Dec 31 14:27:08 2008 @@ -6,6 +6,8 @@ - Deprecated session_register(), session_unregister() and session_is_registered(). (Hannes) +- Changed dl() to be disabled by default. Enabled only when explicitly + registered by the SAPI layer. Enabled only with CLI, CGI and EMBED. (Dmitry) - Changed opendir(), dir() and scandir() to use default context when no context argument is passed. (Sara) - Changed open_basedir to allow tightening in runtime contexts. (Sara) http://cvs.php.net/viewvc.cgi/php-src/ext/standard/basic_functions.c?r1= 1.725.2.31.2.64.2.79r2=1.725.2.31.2.64.2.80diff_format=u Index: php-src/ext/standard/basic_functions.c diff -u php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.79 php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.80 --- php-src/ext/standard/basic_functions.c:1.725.2.31.2.64.2.79 Wed Dec 31 11:15:44 2008 +++ php-src/ext/standard/basic_functions.c Wed Dec 31 14:27:09 2008 @@ -18,7 +18,7 @@ +--+ */ -/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.79 2008/12/31 11:15:44 sebastian Exp $ */ +/* $Id: basic_functions.c,v 1.725.2.31.2.64.2.80 2008/12/31 14:27:09 helly Exp $ */ #include php.h #include php_streams.h @@ -3025,9 +3025,6 @@ PHP_FE(is_scalar, arginfo_is_scalar) PHP_FE(is_callable, arginfo_is_callable) - /* functions from dl.c */ - PHP_FE(dl, arginfo_dl) - /* functions from file.c */ PHP_FE(pclose, arginfo_pclose) PHP_FE(popen, arginfo_popen) http://cvs.php.net/viewvc.cgi/php-src/main/SAPI.h?r1=1.114.2.1.2.3.2.5r 2=1.114.2.1.2.3.2.6diff_format=u Index: php-src/main/SAPI.h diff -u php-src/main/SAPI.h:1.114.2.1.2.3.2.5 php-src/main/SAPI.h:1.114.2.1.2.3.2.6 --- php-src/main/SAPI.h:1.114.2.1.2.3.2.5 Wed Dec 31 11:15:47 2008 +++ php-src/main/SAPI.h Wed Dec 31 14:27:09 2008 @@ -16,7 +16,7 @@ +--+ */ -/* $Id: SAPI.h,v 1.114.2.1.2.3.2.5 2008/12/31 11:15:47 sebastian Exp $ */ +/* $Id: SAPI.h,v 1.114.2.1.2.3.2.6 2008/12/31 14:27:09 helly Exp $ */ #ifndef SAPI_H #define SAPI_H @@ -264,6 +264,7 @@ int phpinfo_as_text; char *ini_entries; + const zend_function_entry *additional_functions; }; http://cvs.php.net/viewvc.cgi/php-src/main/main.c?r1=1.640.2.23.2.57.2.4 0r2=1.640.2.23.2.57.2.41diff_format=u Index: php-src/main/main.c diff -u php-src/main/main.c:1.640.2.23.2.57.2.40 php-src/main/main.c:1.640.2.23.2.57.2.41 --- php-src/main/main.c:1.640.2.23.2.57.2.40Wed Dec 31 14:05:22 2008 +++ php-src/main/main.c Wed Dec 31 14:27:09 2008 @@ -18,7 +18,7 @@ +--+ */ -/* $Id: main.c,v 1.640.2.23.2.57.2.40 2008/12/31 14:05:22 helly Exp $ */ +/* $Id: main.c,v 1.640.2.23.2.57.2.41 2008/12/31 14:27:09 helly Exp $ */ /* {{{ includes */ @@ -1910,6 +1910,15 @@ /* start Zend extensions */ zend_startup_extensions(); + /* register additional functions */ + if (sapi_module.additional_functions) { + if (zend_hash_find(module_registry, standard, sizeof(standard), (void**)module)==SUCCESS) { + EG(current_module) = module; + zend_register_functions(NULL, sapi_module.additional_functions, NULL, MODULE_PERSISTENT TSRMLS_CC); + EG(current_module) = NULL; + } + } + /* make core report what it should */ if
Re: [PHP-CVS] cvs: php-src(PHP_5_3) / NEWS /ext/standard basic_functions.c /main SAPI.h main.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/embed php_embed.c
hi Marcus, On Wed, Dec 31, 2008 at 3:27 PM, Marcus Boerger he...@php.net wrote: arginfo_popen) http://cvs.php.net/viewvc.cgi/php-src/main/SAPI.h?r1=1.114.2.1.2.3.2.5r2=1.114.2.1.2.3.2.6diff_format=u Index: php-src/main/SAPI.h diff -u php-src/main/SAPI.h:1.114.2.1.2.3.2.5 php-src/main/SAPI.h:1.114.2.1.2.3.2.6 --- php-src/main/SAPI.h:1.114.2.1.2.3.2.5 Wed Dec 31 11:15:47 2008 +++ php-src/main/SAPI.h Wed Dec 31 14:27:09 2008 @@ -16,7 +16,7 @@ +--+ */ -/* $Id: SAPI.h,v 1.114.2.1.2.3.2.5 2008/12/31 11:15:47 sebastian Exp $ */ +/* $Id: SAPI.h,v 1.114.2.1.2.3.2.6 2008/12/31 14:27:09 helly Exp $ */ #ifndef SAPI_H #define SAPI_H @@ -264,6 +264,7 @@ int phpinfo_as_text; char *ini_entries; + const zend_function_entry *additional_functions; }; This addition breaks the builds, zend_function_entry is not defined at this point and breaks as long as one includes SAPI.h (like ext/filter). Should zend_API.h not included in zend.h? or do you want to manually include it in mainco? Cheers, -- Pierre http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php