[PHP-DEV] sapi_spache2.c + 4.2.0
httpd-2.0 folks are pushing for GA, in order for apache2filter to compile revisionn 1.63 of sapi/apache2filter/sapi_apache2.c needs to be included in 4.2.0 (or next RC, whichever comes first). can somebody merge 1.63 changes into the 4.2.0 branch? -- PHP Development Mailing List http://www.php.net/ To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DEV] virtual vs apache_sub_req
any reason why the 2.0 version shouldn't be the same name as the 1.3 version? same with get_all_headers vs getallheaders Index: sapi/apache2filter/php_functions.c === RCS file: /repository/php4/sapi/apache2filter/php_functions.c,v retrieving revision 1.13 diff -u -r1.13 php_functions.c --- sapi/apache2filter/php_functions.c 6 Dec 2001 00:53:58 - 1.13 +++ sapi/apache2filter/php_functions.c 6 Dec 2001 00:55:39 - @@ -48,9 +48,9 @@ return ap_sub_req_lookup_uri(Z_STRVAL_PP(p1), ctx-f-r, ctx-f-next); } -/* {{{ proto bool apache_sub_req(string uri) +/* {{{ proto bool virtual(string uri) Perform an apache sub-request */ -PHP_FUNCTION(apache_sub_req) +PHP_FUNCTION(virtual) { request_rec *rr; @@ -106,9 +106,9 @@ RETURN_FALSE; } -/* {{{ proto array get_all_headers(void) +/* {{{ proto array getallheaders(void) Fetch all HTTP request headers */ -PHP_FUNCTION(get_all_headers) +PHP_FUNCTION(getallheaders) { php_struct *ctx; apr_array_header_t *arr; @@ -134,8 +134,8 @@ static function_entry apache_functions[] = { PHP_FE(apache_lookup_uri, NULL) - PHP_FE(apache_sub_req, NULL) - PHP_FE(get_all_headers, NULL) + PHP_FE(virtual, NULL) + PHP_FE(getallheaders, NULL) {0} }; -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] more 1.3 vs 2.0 differences
- apache_lookup_uri with the apache 2.0 module returns an array rather than a class. any objections to making it behave the the 1.3 based module? - the 2.0 getallheaders lets the authorization header through whereas 1.3 does: PG(safe_mode) !strncasecmp(tenv[i].key, authorization, 13) - the 2.0 module is missing the following functions: apachelog, apache_note, apache_setenv, apache_child_terminate. - and the PHP_MINFO_FUNCTION() doesn't do anything in the 2.0 module. i can work on these, unless there are reasons not to support them? -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DEV] fwd: buildconf troubles
On Mon, 17 Sep 2001, Hartmut Holzgraefe wrote: on one of the boxes everything worked fine again after commenting out the DLOPEN_SELF stuff in Zend/Zend.m4 while the other one still gives lots of undefined macros i tried this, all undefined macros go away and php is building for me again. thanks! -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] fwd: buildconf troubles
still stuck on this with current cvs, anybody else seeing this? From [EMAIL PROTECTED] Thu Aug 30 09:47:20 2001 -0700 Status: X-Status: X-Keywords: Date: Thu, 30 Aug 2001 09:47:20 -0700 (PDT) From: Doug MacEachern [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: buildconf troubles Message-ID: [EMAIL PROTECTED] MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII i've done a fresh checkout and having problems building, below is the output from buildconf. % autoconf --version Autoconf version 2.13 % libtool --version ltmain.sh (GNU libtool) 1.4 (1.920 2001/04/24 23:26:18) any ideas? % ./buildconf rebuilding Makefile templates rebuilding configure autoconf: Undefined macros: ***BUG in Autoconf--please report*** AC_TRY_DLOPEN_SELF configure.in:162:AC_MSG_RESULT($PHP_SAPI) configure.in:182:AC_MSG_RESULT($php_cv_cc_dashr) configure.in:192: AC_MSG_RESULT($php_cv_cc_rpath) configure.in:220: AC_DEFINE(HAVE_LIBSOCKET,1,[ ]) ], [ configure.in:238: AC_DEFINE(HAVE_LIBNSL,1,[ ]) ],[ configure.in:241: AC_DEFINE(HAVE_LIBNSL,1,[ ]) ], []) configure.in:267: AC_DEFINE(HAVE_LIBSOCKET,1,[ ]) ], [ configure.in:270: AC_DEFINE(HAVE_LIBRESOLV,1,[ ]) configure.in:363: AC_DEFINE(HAVE_IPV6,1,[Whether you have IPv6 support]) configure.in:437: AC_DEFINE(HAVE_GETADDRINFO,1,[Define if you have the getaddrinfo function]) configure.in:463:dnl AC_MSG_RESULT($ac_cv_type_in_addr_t) configure.in:465: AC_DEFINE(in_addr_t, u_int, [ ]) configure.in:528: AC_DEFINE(PHP_SAFE_MODE,1,[ ]) configure.in:530: AC_DEFINE(PHP_SAFE_MODE,0,[ ]) configure.in:540: AC_DEFINE(PHP_SAFE_MODE_EXEC_DIR,/usr/local/php/bin, [ ]) configure.in:541: AC_MSG_RESULT(/usr/local/php/bin) configure.in:543: AC_DEFINE_UNQUOTED(PHP_SAFE_MODE_EXEC_DIR,$withval, [ ]) configure.in:544: AC_MSG_RESULT($withval) configure.in:547: AC_DEFINE(PHP_SAFE_MODE_EXEC_DIR,/usr/local/php/bin, [ ]) configure.in:548: AC_MSG_RESULT(/usr/local/php/bin) configure.in:551: AC_DEFINE(PHP_SAFE_MODE_EXEC_DIR,/usr/local/php/bin, [ ]) configure.in:552: AC_MSG_RESULT(/usr/local/php/bin) configure.in:569: AC_DEFINE(PHP_SIGCHILD, 1, [ ]) configure.in:571: AC_DEFINE(PHP_SIGCHILD, 0, [ ]) configure.in:578: AC_DEFINE(MAGIC_QUOTES, 1, [ ]) configure.in:580: AC_DEFINE(MAGIC_QUOTES, 0, [ ]) configure.in:603: AC_DEFINE(DEFAULT_SHORT_OPEN_TAG,1,[ ]) configure.in:605: AC_DEFINE(DEFAULT_SHORT_OPEN_TAG,0,[ ]) configure.in:616:AC_DEFINE(HAVE_DMALLOC,1,[Whether you have dmalloc]) configure.in:629: AC_DEFINE(HAVE_PHP_STREAM, 1, [Whether to use php streams]) configure.in:635: AC_DEFINE(HAVE_CRYPT,1,[ ]) configure.in:655:AC_MSG_RESULT($PHP_VERSIONING) configure.in:706: AC_DEFINE(ZTS,1,[ ]) configure.in:819:AC_DEFINE_UNQUOTED(PHP_BUILD_DATE,$PHP_BUILD_DATE,[PHP build date]) configure.in:821:AC_DEFINE_UNQUOTED(PHP_UNAME,$PHP_UNAME,[uname -a output]) configure.in:823:AC_DEFINE_UNQUOTED(PHP_OS,$PHP_OS,[uname output]) configure.in:88:AC_MSG_RESULT($1.$2 (ok)) rebuilding main/php_config.h.in -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] buildconf troubles
i've done a fresh checkout and having problems building, below is the output from buildconf. % autoconf --version Autoconf version 2.13 % libtool --version ltmain.sh (GNU libtool) 1.4 (1.920 2001/04/24 23:26:18) any ideas? % ./buildconf rebuilding Makefile templates rebuilding configure autoconf: Undefined macros: ***BUG in Autoconf--please report*** AC_TRY_DLOPEN_SELF configure.in:162:AC_MSG_RESULT($PHP_SAPI) configure.in:182:AC_MSG_RESULT($php_cv_cc_dashr) configure.in:192: AC_MSG_RESULT($php_cv_cc_rpath) configure.in:220: AC_DEFINE(HAVE_LIBSOCKET,1,[ ]) ], [ configure.in:238: AC_DEFINE(HAVE_LIBNSL,1,[ ]) ],[ configure.in:241: AC_DEFINE(HAVE_LIBNSL,1,[ ]) ], []) configure.in:267: AC_DEFINE(HAVE_LIBSOCKET,1,[ ]) ], [ configure.in:270: AC_DEFINE(HAVE_LIBRESOLV,1,[ ]) configure.in:363: AC_DEFINE(HAVE_IPV6,1,[Whether you have IPv6 support]) configure.in:437: AC_DEFINE(HAVE_GETADDRINFO,1,[Define if you have the getaddrinfo function]) configure.in:463:dnl AC_MSG_RESULT($ac_cv_type_in_addr_t) configure.in:465: AC_DEFINE(in_addr_t, u_int, [ ]) configure.in:528: AC_DEFINE(PHP_SAFE_MODE,1,[ ]) configure.in:530: AC_DEFINE(PHP_SAFE_MODE,0,[ ]) configure.in:540: AC_DEFINE(PHP_SAFE_MODE_EXEC_DIR,/usr/local/php/bin, [ ]) configure.in:541: AC_MSG_RESULT(/usr/local/php/bin) configure.in:543: AC_DEFINE_UNQUOTED(PHP_SAFE_MODE_EXEC_DIR,$withval, [ ]) configure.in:544: AC_MSG_RESULT($withval) configure.in:547: AC_DEFINE(PHP_SAFE_MODE_EXEC_DIR,/usr/local/php/bin, [ ]) configure.in:548: AC_MSG_RESULT(/usr/local/php/bin) configure.in:551: AC_DEFINE(PHP_SAFE_MODE_EXEC_DIR,/usr/local/php/bin, [ ]) configure.in:552: AC_MSG_RESULT(/usr/local/php/bin) configure.in:569: AC_DEFINE(PHP_SIGCHILD, 1, [ ]) configure.in:571: AC_DEFINE(PHP_SIGCHILD, 0, [ ]) configure.in:578: AC_DEFINE(MAGIC_QUOTES, 1, [ ]) configure.in:580: AC_DEFINE(MAGIC_QUOTES, 0, [ ]) configure.in:603: AC_DEFINE(DEFAULT_SHORT_OPEN_TAG,1,[ ]) configure.in:605: AC_DEFINE(DEFAULT_SHORT_OPEN_TAG,0,[ ]) configure.in:616:AC_DEFINE(HAVE_DMALLOC,1,[Whether you have dmalloc]) configure.in:629: AC_DEFINE(HAVE_PHP_STREAM, 1, [Whether to use php streams]) configure.in:635: AC_DEFINE(HAVE_CRYPT,1,[ ]) configure.in:655:AC_MSG_RESULT($PHP_VERSIONING) configure.in:706: AC_DEFINE(ZTS,1,[ ]) configure.in:819:AC_DEFINE_UNQUOTED(PHP_BUILD_DATE,$PHP_BUILD_DATE,[PHP build date]) configure.in:821:AC_DEFINE_UNQUOTED(PHP_UNAME,$PHP_UNAME,[uname -a output]) configure.in:823:AC_DEFINE_UNQUOTED(PHP_OS,$PHP_OS,[uname output]) configure.in:88:AC_MSG_RESULT($1.$2 (ok)) rebuilding main/php_config.h.in -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] generated ChangeLog
is the script for generating the ChangeLog available somewhere? very cool, would like to use it for modperl-2.0 and httpd-test projects. thanks. -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] ext/standard/html.c breakage
one the php tests (tests/strings/003.phpt) that has been ported to httpd-test is failing with current cvs: ?php setlocale (LC_CTYPE, C); echo htmlspecialchars (\åÄ\n); echo htmlentities (\åÄ\n); ? the 'echo htmlspecialchars ...' does not echo anything. problem seems to be caused by this change: 2001-08-23 Wez Furlong [EMAIL PROTECTED] * ext/standard/html.c: - Add support for chinese encodings to htmlentities/htmlspecialchars (patch from Alan Knowles [EMAIL PROTECTED]) if i: % cvs up -r1.32 ext/standard/html.c things are back to normal. -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] [patch] don't filter proxy requests
if mod_proxy+ProxyPass are enabled, php will try to filter the output of proxy requests for *.php files. patch below prevents that.. Index: sapi/apache2filter/sapi_apache2.c === RCS file: /repository/php4/sapi/apache2filter/sapi_apache2.c,v retrieving revision 1.46 diff -u -r1.46 sapi_apache2.c --- sapi/apache2filter/sapi_apache2.c 18 Aug 2001 01:59:38 - 1.46 +++ sapi/apache2filter/sapi_apache2.c 19 Aug 2001 19:45:43 - @@ -315,6 +315,10 @@ void *conf = ap_get_module_config(f-r-per_dir_config, php4_module); TSRMLS_FETCH(); +if (f-r-proxyreq) { +return ap_pass_brigade(f-next, bb); +} + ctx = SG(server_context); INIT_CTX; -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] [patch] php_insert_filter
with the patch below, the 1.x configuration: AddType application/x-httpd-php .php will also work with 2.0, without the extra config that is currently required: IfModule sapi_apache2.c Files *.php SetOutputFilter PHP SetInputFilter PHP /Files /IfModule Index: sapi/apache2filter/sapi_apache2.c === RCS file: /repository/php4/sapi/apache2filter/sapi_apache2.c,v retrieving revision 1.48 diff -u -r1.48 sapi_apache2.c --- sapi/apache2filter/sapi_apache2.c 19 Aug 2001 21:07:50 - 1.48 +++ sapi/apache2filter/sapi_apache2.c 20 Aug 2001 04:40:19 - @@ -417,9 +417,19 @@ php_apache_register_module(); } +static void php_insert_filter(request_rec *r) +{ + if (r-content_type + strcmp(r-content_type, application/x-httpd-php) == 0) { + ap_add_output_filter(PHP, NULL, r, r-connection); + ap_add_input_filter(PHP, NULL, r, r-connection); + } +} + static void php_register_hook(apr_pool_t *p) { ap_hook_child_init(php_apache_server_startup, NULL, NULL, APR_HOOK_MIDDLE); + ap_hook_insert_filter(php_insert_filter, NULL, NULL, APR_HOOK_MIDDLE); ap_register_output_filter(PHP, php_output_filter, AP_FTYPE_CONTENT); ap_register_input_filter(PHP, php_input_filter, AP_FTYPE_CONTENT); } -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DEV] another segv in sapi_apache2
doesn't seem right for this flush function to be called at server shutdown, ctx-f and ctx-f-r won't be alive at this point. so i'm not sure if this is the right fix, but patch below stops segv. with this and the cleanup_register patch bloom committed for me, all php tests in httpd-test are now passing under 2.0. also working fine through mod_ssl (t/TEST -ssl) #0 php_apache_sapi_flush (server_context=0x0) at sapi_apache2.c:175 175bb = apr_brigade_create(ctx-f-r-pool); (gdb) where #0 php_apache_sapi_flush (server_context=0x0) at sapi_apache2.c:175 #1 0x40218eb6 in sapi_flush (tsrm_ls=0x8298040) at SAPI.c:559 #2 0x40214e07 in php_module_shutdown (tsrm_ls=0x8298040) at main.c:994 #3 0x40214dd1 in php_module_shutdown_wrapper (sapi_globals=0x402cf6a0) at main.c:973 #4 0x40212b11 in php_apache_server_shutdown (tmp=0x0) at sapi_apache2.c:397 #5 0x80e4d8c in run_cleanups (c=0x81e88b4) at apr_pools.c:771 #6 0x80e4ed4 in apr_pool_clear (a=0x81e887c) at apr_pools.c:874 #7 0x80e4f28 in apr_pool_destroy (a=0x81e887c) at apr_pools.c:920 #8 0x80ba9ce in clean_child_exit (code=0) at prefork.c:236 ... Index: sapi/apache2filter/sapi_apache2.c === RCS file: /repository/php4/sapi/apache2filter/sapi_apache2.c,v retrieving revision 1.43 diff -u -r1.43 sapi_apache2.c --- sapi/apache2filter/sapi_apache2.c 17 Aug 2001 22:25:13 - 1.43 +++ sapi/apache2filter/sapi_apache2.c 18 Aug 2001 01:04:47 - @@ -163,6 +163,10 @@ apr_bucket_brigade *bb; apr_bucket *b; +if (!server_context) { +return; +} + /* Send a flush bucket down the filter chain. The current default * handler seems to act on the first flush bucket, but ignores * all further flush buckets. -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DEV] another segv in sapi_apache2
thanks. this one gets rid of a warning... Index: sapi_apache2.c === RCS file: /repository/php4/sapi/apache2filter/sapi_apache2.c,v retrieving revision 1.45 diff -u -r1.45 sapi_apache2.c --- sapi_apache2.c 18 Aug 2001 01:36:29 - 1.45 +++ sapi_apache2.c 18 Aug 2001 01:55:32 - @@ -238,7 +238,7 @@ } static int php_input_filter(ap_filter_t *f, apr_bucket_brigade *bb, - ap_input_mode_t mode, apr_size_t *readbytes) + ap_input_mode_t mode, apr_off_t *readbytes) { php_struct *ctx; long old_index; -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]