|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2002-08-31 00:14 UTC] kalowsky@php.net
[2002-09-03 18:14 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Thu Oct 08 01:00:01 2026 UTC |
First I modified php_functions.c and changed "MODULE_MAGIC_AT_LEAST" to "AP_MODULE_MAGIC_AT_LEAST" Then I proceeded with building: ./configure --with-apxs2=/usr/local/apache2/bin/apxs make This eventually gave the following errors: sapi_apache2.c: In function `php_register_hook': sapi_apache2.c:534: warning: passing arg 3 of `ap_register_output_filter' makes pointer from integer without a cast sapi_apache2.c:534: too few arguments to function `ap_register_output_filter' sapi_apache2.c:535: warning: passing arg 3 of `ap_register_input_filter' makes pointer from integer without a cast sapi_apache2.c:535: too few arguments to function `ap_register_input_filter' I tracked this down to a change made recently in Apache's include file util_filter.h. The older functions are defined as: AP_DECLARE(ap_filter_rec_t *) ap_register_input_filter(const char *name, ap_in_filter_func filter_func, ap_filter_type ftype); AP_DECLARE(ap_filter_rec_t *) ap_register_output_filter(const char *name, ap_out_filter_func filter_func, ap_filter_type ftype); The newer functions have an additional argument: AP_DECLARE(ap_filter_rec_t *) ap_register_input_filter(const char *name, ap_in_filter_func filter_func, ap_init_filter_func filter_init, ap_filter_type ftype); AP_DECLARE(ap_filter_rec_t *) ap_register_output_filter(const char *name, ap_out_filter_func filter_func, ap_init_filter_func filter_init, ap_filter_type ftype); Not sure what the appropriate fix is. I just added a NULL to the third argument in the function call to sapi_apache2filter.c and it compiles ok. Here's a diff. --- sapi/apache2filter/sapi_apache2.c.orig Mon May 6 05:42:23 2002 +++ sapi/apache2filter/sapi_apache2.c Fri Aug 30 17:53:22 2002 @@ -531,8 +531,8 @@ ap_hook_post_config(php_apache_server_startup, NULL, NULL, APR_HOOK_MIDDLE); ap_hook_insert_filter(php_insert_filter, NULL, NULL, APR_HOOK_MIDDLE); ap_hook_post_read_request(php_post_read_request, NULL, NULL, APR_HOOK_MIDDLE); - ap_register_output_filter("PHP", php_output_filter, AP_FTYPE_RESOURCE); - ap_register_input_filter("PHP", php_input_filter, AP_FTYPE_RESOURCE); + ap_register_output_filter("PHP", php_output_filter, NULL, AP_FTYPE_RESOURCE); + ap_register_input_filter("PHP", php_input_filter, NULL, AP_FTYPE_RESOURCE); } AP_MODULE_DECLARE_DATA module php4_module = { Apache starts up but doesn't process any PHP code. Any hints would be appreciated.