cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/02/19 15:55:23 Modified:.Changes lib/Apache compat.pm t/response/TestCompat apache.pm xs/Apache/Response Apache__Response.h xs/maps modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: move $r->send_http_header implementation to Apache::compat. This allows the 1.0 code to run unmodified if $r->send_http_header is called before the response change. we already handle the check whether content_type was set, when deciding whether the headers are to be parsed inside modperl_wbucket_pass(). Revision ChangesPath 1.130 +6 -0 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.129 retrieving revision 1.130 diff -u -r1.129 -r1.130 --- Changes 19 Feb 2003 14:14:35 - 1.129 +++ Changes 19 Feb 2003 23:55:22 - 1.130 @@ -10,6 +10,12 @@ =item 1.99_09-dev +move $r->send_http_header implementation to Apache::compat. This +allows the 1.0 code to run unmodified if $r->send_http_header is +called before the response change. we already handle the check whether +content_type was set, when deciding whether the headers are to be +parsed inside modperl_wbucket_pass(). [Stas] + fixes to Apache::compat. make $r->connection->auth_type interface with r->ap_auth_type. make both $r->connection->auth_type and $r->connection->user writable. [Geoffrey Young] 1.81 +5 -0 modperl-2.0/lib/Apache/compat.pm Index: compat.pm === RCS file: /home/cvs/modperl-2.0/lib/Apache/compat.pm,v retrieving revision 1.80 retrieving revision 1.81 diff -u -r1.80 -r1.81 --- compat.pm 19 Feb 2003 14:14:36 - 1.80 +++ compat.pm 19 Feb 2003 23:55:23 - 1.81 @@ -154,6 +154,11 @@ return Apache::current_callback(); } +sub send_http_header { +my ($r, $type) = @_; +$r->content_type($type) if defined $type; +} + #to support $r->server_root_relative *server_root_relative = \&Apache::server_root_relative; 1.5 +3 -0 modperl-2.0/t/response/TestCompat/apache.pm Index: apache.pm === RCS file: /home/cvs/modperl-2.0/t/response/TestCompat/apache.pm,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- apache.pm 17 Feb 2003 09:03:17 - 1.4 +++ apache.pm 19 Feb 2003 23:55:23 - 1.5 @@ -55,3 +55,6 @@ 1; +__END__ +# so we can test whether send_httpd_header() works fine +PerlOptions +ParseHeaders 1.9 +0 -22 modperl-2.0/xs/Apache/Response/Apache__Response.h Index: Apache__Response.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Response/Apache__Response.h,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- Apache__Response.h17 Jan 2003 02:26:31 - 1.8 +++ Apache__Response.h19 Feb 2003 23:55:23 - 1.9 @@ -13,28 +13,6 @@ rcfg->wbucket->header_parse = 0; \ } -/* XXX: should only be part of Apache::compat */ -static MP_INLINE void -mpxs_Apache__RequestRec_send_http_header(pTHX_ request_rec *r, - const char *type) -{ -MP_dRCFG; - -if (type) { -ap_set_content_type(r, apr_pstrdup(r->pool, type)); -} - -if (rcfg->wbucket) { -/* turn off PerlOptions +ParseHeaders */ -rcfg->wbucket->header_parse = 0; -} -else { -/* the response is not initialized yet */ -Perl_croak(aTHX_ "send_http_header() can't be called before " - "the response phase"); -} -} - static MP_INLINE void mpxs_Apache__RequestRec_set_last_modified(request_rec *r, apr_time_t mtime) { 1.54 +0 -1 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.53 retrieving revision 1.54 diff -u -r1.53 -r1.54 --- modperl_functions.map 17 Feb 2003 09:03:17 - 1.53 +++ modperl_functions.map 19 Feb 2003 23:55:23 - 1.54 @@ -56,7 +56,6 @@ MODULE=Apache::Response PACKAGE=Apache::RequestRec DEFINE_send_cgi_header | | request_rec *:r, SV *:buffer - mpxs_Apache__RequestRec_send_http_header | | r, type=NULL mpxs_Apache__RequestRec_set_last_modified | | r, mtime=0 1.105 +0 -18 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm =
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/30 20:20:20 Modified:src/modules/perl modperl_global.c modperl_global.h xs/Apache/RequestUtil Apache__RequestUtil.h xs/tables/current/ModPerl FunctionTable.pm Log: expose modperl_global_request (needed in external apps written in XS ) Revision ChangesPath 1.7 +24 -0 modperl-2.0/src/modules/perl/modperl_global.c Index: modperl_global.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_global.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- modperl_global.c 22 May 2002 18:53:33 - 1.6 +++ modperl_global.c 31 Jan 2003 04:20:20 - 1.7 @@ -26,6 +26,30 @@ MpReqSET_GLOBAL_REQUEST_On(rcfg); } +/* get/set */ +request_rec *modperl_global_request(pTHX_ SV *svr) +{ +request_rec *cur = NULL; +apr_status_t status = modperl_tls_get_request_rec(&cur); + +if (status != APR_SUCCESS) { +/* an internal problem */ +Perl_croak(aTHX_ "failed to retrieve the request object"); +} + +if (!cur) { +/* wrong configuration */ +Perl_croak(aTHX_ "Global $r object is not available. Set:\n" + "\tPerlOptions +GlobalRequest\nin httpd.conf"); +} + +if (svr) { +modperl_global_request_obj_set(aTHX_ svr); +} + +return cur; +} + void modperl_global_request_obj_set(pTHX_ SV *svr) { /* XXX: support sublassing */ 1.4 +2 -0 modperl-2.0/src/modules/perl/modperl_global.h Index: modperl_global.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_global.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- modperl_global.h 4 May 2001 05:49:19 - 1.3 +++ modperl_global.h 31 Jan 2003 04:20:20 - 1.4 @@ -18,6 +18,8 @@ void modperl_global_request_cfg_set(request_rec *r); +request_rec *modperl_global_request(pTHX_ SV *svr); + void modperl_global_request_set(request_rec *r); void modperl_global_request_obj_set(pTHX_ SV *svr); 1.17 +2 -19 modperl-2.0/xs/Apache/RequestUtil/Apache__RequestUtil.h Index: Apache__RequestUtil.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestUtil/Apache__RequestUtil.h,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- Apache__RequestUtil.h 31 Jan 2003 03:15:23 - 1.16 +++ Apache__RequestUtil.h 31 Jan 2003 04:20:20 - 1.17 @@ -85,25 +85,8 @@ static MP_INLINE request_rec *mpxs_Apache_request(pTHX_ SV *classname, SV *svr) { -request_rec *cur = NULL; -apr_status_t status = modperl_tls_get_request_rec(&cur); - -if (status != APR_SUCCESS) { -/* an internal problem */ -Perl_croak(aTHX_ "failed to retrieve the request object"); -} - -if (!cur) { -/* wrong configuration */ -Perl_croak(aTHX_ "Global $r object is not available. Set:\n" - "\tPerlOptions +GlobalRequest\nin httpd.conf"); -} - -if (svr) { -modperl_global_request_obj_set(aTHX_ svr); -} - -return cur; +/* ignore classname */ +return modperl_global_request(aTHX_ svr); } static MP_INLINE 1.104 +14 -0 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.103 retrieving revision 1.104 diff -u -r1.103 -r1.104 --- FunctionTable.pm 29 Jan 2003 03:56:00 - 1.103 +++ FunctionTable.pm 31 Jan 2003 04:20:20 - 1.104 @@ -1494,6 +1494,20 @@ 'args' => [] }, { +'return_type' => 'request_rec *', +'name' => 'modperl_global_request', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'SV *', +'name' => 'svr' + } +] + }, + { 'return_type' => 'SV *', 'name' => 'modperl_dir_config', 'attr' => [
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/28 19:56:00 Modified:.Changes t/response/TestApache conftree.pm xs/Apache/Directive Apache__Directive.h xs/maps modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: New Apache::Directive methods: as_hash(), lookup() + tests Submitted by: Philippe M. Chiasson <[EMAIL PROTECTED]> Reviewed by: stas Revision ChangesPath 1.117 +3 -0 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.116 retrieving revision 1.117 diff -u -r1.116 -r1.117 --- Changes 29 Jan 2003 01:04:33 - 1.116 +++ Changes 29 Jan 2003 03:56:00 - 1.117 @@ -10,6 +10,9 @@ =item 1.99_09-dev +New Apache::Directive methods: as_hash(), lookup() + tests + docs +[Philippe M. Chiasson <[EMAIL PROTECTED]>] + Stacked handlers chain execution is now aborted when a handler returns something other than OK or DECLINED [Stas] 1.5 +25 -27modperl-2.0/t/response/TestApache/conftree.pm Index: conftree.pm === RCS file: /home/cvs/modperl-2.0/t/response/TestApache/conftree.pm,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- conftree.pm 19 May 2002 01:12:24 - 1.4 +++ conftree.pm 29 Jan 2003 03:56:00 - 1.5 @@ -4,6 +4,7 @@ use warnings FATAL => 'all'; use Apache::Test; +use Apache::TestUtil; use Apache::TestConfig (); use Apache::Directive (); @@ -14,7 +15,7 @@ my $r = shift; my $cfg = Apache::Test::config(); -plan $r, tests => 7; +plan $r, tests => 8; ok $cfg; @@ -26,43 +27,40 @@ ok $tree; -my $port = find_config_val($tree, 'Listen'); +my $port = $tree->lookup('Listen'); -ok $port; +ok t_cmp($vars->{port}, $port); -ok $port == $vars->{port}; +my $documentroot = $tree->lookup('DocumentRoot'); -my $documentroot = find_config_val($tree, 'DocumentRoot'); +ok t_cmp('HASH' , ref($tree->as_hash()), 'as_hash'); -ok $documentroot; +ok t_cmp(qq("$vars->{documentroot}"), $documentroot); -ok $documentroot eq qq("$vars->{documentroot}"); +ok t_cmp(qq("$vars->{documentroot}"), $tree->lookup("DocumentRoot")); -Apache::OK; -} - -sub find_config_val { -my($tree, $directive) = @_; +#XXX: This test isn't so good, but its quite problematic to try +#and _really_ compare $cfg and $tree... +{ +my %vhosts = map { +$cfg->{vhosts}{$_}{name} => { %{$cfg->{vhosts}{$_}}, index => $_ } +} keys %{$cfg->{vhosts}}; -while ($tree) { -if ($directive eq $tree->directive) { -return $tree->args; +for my $v (keys %vhosts) { +$vhosts{ $vhosts{$v}{index} } = $vhosts{$v}; } -if (my $kid = $tree->first_child) { -$tree = $kid; -} elsif (my $next = $tree->next) { -$tree = $next; -} -else { -if (my $parent = $tree->parent) { -$tree = $parent->next; -} -else { -$tree = undef; +my $vhost_failed; +for my $vhost ($tree->lookup("VirtualHost")) { +unless (exists $vhosts{$vhost->{'ServerName'} +|| $vhost->{'PerlProcessConnectionHandler'}}) { +$vhost_failed++; } } + +ok !$vhost_failed; } -} +Apache::OK; +} 1; 1.6 +162 -0modperl-2.0/xs/Apache/Directive/Apache__Directive.h Index: Apache__Directive.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Directive/Apache__Directive.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- Apache__Directive.h 5 Sep 2002 01:47:39 - 1.5 +++ Apache__Directive.h 29 Jan 2003 03:56:00 - 1.6 @@ -17,3 +17,165 @@ return sv; } + + +/* Adds an entry to a hash, vivifying hash/array for multiple entries */ +static void hash_insert(pTHX_ HV *hash, const char *key, +int keylen, const char *args, +int argslen, SV *value) +{ +HV *subhash; +AV *args_array; +SV **hash_ent = hv_fetch(hash, key, keylen, 0); + +if (value) { +if (!hash_ent) { +subhash = newHV(); +hv_store(hash, key, keylen, newRV_noinc((SV *)subhash), 0); +} +else { +subhash = (HV *)SvRV(*hash_ent); +} + +hv_store(subhash,
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/23 23:48:01 Modified:src/modules/perl modperl_filter.c modperl_filter.h xs/Apache/Filter Apache__Filter.h xs/tables/current/ModPerl FunctionTable.pm Log: drop the idx argument in modperl_filter_runtime_add, we don't need it Revision ChangesPath 1.47 +1 -1 modperl-2.0/src/modules/perl/modperl_filter.c Index: modperl_filter.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.c,v retrieving revision 1.46 retrieving revision 1.47 diff -u -r1.46 -r1.47 --- modperl_filter.c 24 Jan 2003 07:39:29 - 1.46 +++ modperl_filter.c 24 Jan 2003 07:48:00 - 1.47 @@ -728,7 +728,7 @@ r->connection->input_filters); } -void modperl_filter_runtime_add(pTHX_ request_rec *r, conn_rec *c, int idx, +void modperl_filter_runtime_add(pTHX_ request_rec *r, conn_rec *c, const char *name, modperl_filter_add_t addfunc, SV *callback, const char *type) 1.19 +1 -1 modperl-2.0/src/modules/perl/modperl_filter.h Index: modperl_filter.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.h,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- modperl_filter.h 24 Jan 2003 07:39:29 - 1.18 +++ modperl_filter.h 24 Jan 2003 07:48:00 - 1.19 @@ -86,7 +86,7 @@ const char *buf, apr_size_t *len); -void modperl_filter_runtime_add(pTHX_ request_rec *r, conn_rec *c, int idx, +void modperl_filter_runtime_add(pTHX_ request_rec *r, conn_rec *c, const char *name, modperl_filter_add_t addfunc, SV *callback, const char *type); 1.24 +0 -4 modperl-2.0/xs/Apache/Filter/Apache__Filter.h Index: Apache__Filter.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Filter/Apache__Filter.h,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- Apache__Filter.h 24 Jan 2003 07:39:29 - 1.23 +++ Apache__Filter.h 24 Jan 2003 07:48:01 - 1.24 @@ -148,7 +148,6 @@ modperl_filter_runtime_add(aTHX_ r, r->connection, - MP_INPUT_FILTER_HANDLER, MP_FILTER_REQUEST_INPUT_NAME, ap_add_input_filter, callback, @@ -162,7 +161,6 @@ modperl_filter_runtime_add(aTHX_ r, r->connection, - MP_OUTPUT_FILTER_HANDLER, MP_FILTER_REQUEST_OUTPUT_NAME, ap_add_output_filter, callback, @@ -176,7 +174,6 @@ modperl_filter_runtime_add(aTHX_ NULL, c, - MP_INPUT_FILTER_HANDLER, MP_FILTER_CONNECTION_INPUT_NAME, ap_add_input_filter, callback, @@ -190,7 +187,6 @@ modperl_filter_runtime_add(aTHX_ NULL, c, - MP_OUTPUT_FILTER_HANDLER, MP_FILTER_CONNECTION_OUTPUT_NAME, ap_add_output_filter, callback, 1.101 +0 -4 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.100 retrieving revision 1.101 diff -u -r1.100 -r1.101 --- FunctionTable.pm 24 Jan 2003 07:39:29 - 1.100 +++ FunctionTable.pm 24 Jan 2003 07:48:01 - 1.101 @@ -298,10 +298,6 @@ 'name' => 'c' }, { -'type' => 'int', -'name' => 'idx' - }, - { 'type' => 'const char *', 'name' => 'name' },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/23 23:39:29 Modified:.Changes src/modules/perl modperl_filter.c modperl_filter.h xs/Apache/Filter Apache__Filter.h xs/maps apache_functions.map modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Added: t/filter both_str_con_add.t both_str_rec_add.t t/filter/TestFilter both_str_con_add.pm both_str_rec_add.pm Log: - s/filter_add_t/modperl_filter_add_t/ since it's now exposed (needed in Apache::Filter) - implement $r->add_input_filter and $r->add_output_filter $c->add_input_filter and $c->add_output_filter - tests (connection and request) Revision ChangesPath 1.114 +4 -0 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.113 retrieving revision 1.114 diff -u -r1.113 -r1.114 --- Changes 24 Jan 2003 05:09:40 - 1.113 +++ Changes 24 Jan 2003 07:39:28 - 1.114 @@ -10,6 +10,10 @@ =item 1.99_09-dev +Implement $r->add_input_filter and $r->add_output_filter + $c->add_input_filter and $c->add_output_filter +and add tests [Stas] + Skip the handler package::func resolving error, only when the error message matches "Can't locate .*? in @INC", rather than just "Can't locate", since there are many other errors that start with that 1.1 modperl-2.0/t/filter/both_str_con_add.t Index: both_str_con_add.t === use strict; use warnings FATAL => 'all'; use Test; use Apache::TestUtil; use Apache::TestRequest (); my @test_strings = qw(MODPERL 2.0 RULES); plan tests => 1 + @test_strings; my $module = "TestFilter::both_str_con_add"; my $socket = Apache::TestRequest::vhost_socket($module); ok $socket; for my $str (@test_strings) { print $socket "$str\n"; chomp(my $reply = <$socket>); $str = lc $str; $str =~ s/modperl/mod_perl/; ok t_cmp($str, $reply); } 1.1 modperl-2.0/t/filter/both_str_rec_add.t Index: both_str_rec_add.t === use strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestRequest; use Apache::TestUtil; plan tests => 1; my $data = join ' ', 'A'..'Z', 0..9; my $expected = lc $data; # that's what the input filter does $expected =~ s/\s+//g; # that's what the output filter does my $location = '/TestFilter::both_str_rec_add'; my $response = POST_BODY $location, content => $data; ok t_cmp($expected, $response, "lc input and reverse output filters"); 1.1 modperl-2.0/t/filter/TestFilter/both_str_con_add.pm Index: both_str_con_add.pm === package TestFilter::both_str_con_add; # insert an input filter which lowers the case of the data # insert an output filter which adjusts s/modperl/mod_perl/ use strict; use warnings FATAL => 'all'; use Apache::Connection (); use APR::Bucket (); use APR::Brigade (); use APR::Util (); use APR::Const -compile => qw(SUCCESS EOF); use Apache::Const -compile => qw(OK MODE_GETLINE); use Apache::Const -compile => qw(OK); sub pre_connection { my Apache::Connection $c = shift; $c->add_input_filter(\&in_filter); $c->add_output_filter(\&out_filter); return Apache::OK; } sub in_filter { my($filter, $bb, $mode, $block, $readbytes) = @_; while ($filter->read($mode, $block, $readbytes, my $buffer, 1024)) { $filter->print(lc $buffer); } # test that $filter->ctx works here $filter->ctx(1); Apache::OK; } sub out_filter { my $filter = shift; while ($filter->read(my $buffer, 1024)) { $buffer =~ s/modperl/mod_perl/; $filter->print($buffer); } Apache::OK; } sub handler { my Apache::Connection $c = shift; my $bb = APR::Brigade->new($c->pool, $c->bucket_alloc); for (;;) { my $rv = $c->input_filters->get_brigade($bb, Apache::MODE_GETLINE); if ($rv != APR::SUCCESS or $bb->empty) { my $error = APR::strerror($rv); unless ($rv == APR::EOF) { warn "[echo_filter] get_brigade: $error\n"; } $bb->destroy; last; } my $b = APR::Bucket::flush_create($c->bucket_alloc); $bb->insert_tail($b); $c->output_filters->pass_brigade($bb); } Apache::OK; } 1; __END__ PerlPreConnectionHandler TestFilter::both_str
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/22 16:31:28 Modified:src/modules/perl mod_perl.c mod_perl.h modperl_filter.c modperl_util.h .Changes xs/Apache/RequestIO Apache__RequestIO.h xs/Apache/SubRequest Apache__SubRequest.h xs/tables/current/ModPerl FunctionTable.pm Log: - add a new MP_FAILURE_CROAK macro to handle failures - all response functions are now returning status and the callers check and croak on failure or progate them further. Revision ChangesPath 1.147 +10 -4 modperl-2.0/src/modules/perl/mod_perl.c Index: mod_perl.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/mod_perl.c,v retrieving revision 1.146 retrieving revision 1.147 diff -u -r1.146 -r1.147 --- mod_perl.c12 Jan 2003 02:15:58 - 1.146 +++ mod_perl.c23 Jan 2003 00:31:28 - 1.147 @@ -709,12 +709,12 @@ wb->r = r; } -void modperl_response_finish(request_rec *r) +apr_status_t modperl_response_finish(request_rec *r) { MP_dRCFG; /* flush output buffer */ -modperl_wbucket_flush(rcfg->wbucket); +return modperl_wbucket_flush(rcfg->wbucket); } static int modperl_response_handler_run(request_rec *r, int finish) @@ -730,7 +730,10 @@ } if (finish) { -modperl_response_finish(r); +apr_status_t rc = modperl_response_finish(r); +if (rc != APR_SUCCESS) { +retval = rc; +} } return retval; @@ -803,7 +806,10 @@ #endif /* flush output buffer after interpreter is putback */ -modperl_response_finish(r); +apr_status_t rc = modperl_response_finish(r); +if (rc != APR_SUCCESS) { +retval = rc; +} switch (rcfg->status) { case HTTP_MOVED_TEMPORARILY: 1.56 +1 -1 modperl-2.0/src/modules/perl/mod_perl.h Index: mod_perl.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/mod_perl.h,v retrieving revision 1.55 retrieving revision 1.56 diff -u -r1.55 -r1.56 --- mod_perl.h12 Dec 2002 10:05:08 - 1.55 +++ mod_perl.h23 Jan 2003 00:31:28 - 1.56 @@ -88,7 +88,7 @@ void xs_init(pTHX); void modperl_response_init(request_rec *r); -void modperl_response_finish(request_rec *r); +apr_status_t modperl_response_finish(request_rec *r); int modperl_response_handler(request_rec *r); int modperl_response_handler_cgi(request_rec *r); 1.45 +5 -6 modperl-2.0/src/modules/perl/modperl_filter.c Index: modperl_filter.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.c,v retrieving revision 1.44 retrieving revision 1.45 diff -u -r1.44 -r1.45 --- modperl_filter.c 17 Jan 2003 03:08:31 - 1.44 +++ modperl_filter.c 23 Jan 2003 00:31:28 - 1.45 @@ -23,6 +23,8 @@ ap_log_error(APLOG_MARK, APLOG_WARNING, 0, r->server, "%s did not send an HTTP header", r->uri); +/* XXX: bodytext == NULL here */ +return status; } else if (!bodytext) { return APR_SUCCESS; @@ -190,17 +192,14 @@ * first modperl_input_filter_read, so it must be * destroyed at the end of the filter invocation */ -/* XXX: may be the filter must consume all the data? add a - * test to check */ apr_brigade_destroy(filter->bb_in); filter->bb_in = NULL; } -modperl_input_filter_flush(filter); +MP_FAILURE_CROAK(modperl_input_filter_flush(filter)); } else { -modperl_output_filter_flush(filter); +MP_FAILURE_CROAK(modperl_output_filter_flush(filter)); } - return status; } @@ -457,7 +456,7 @@ if (filter->flush && len == 0) { /* if len > 0 then $filter->write will flush */ -modperl_output_filter_flush(filter); +MP_FAILURE_CROAK(modperl_output_filter_flush(filter)); } return len; 1.38 +7 -0 modperl-2.0/src/modules/perl/modperl_util.h Index: modperl_util.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_util.h,v retrieving revision 1.37 retrieving revision 1.38 diff -u -r1.37 -r1.38 --- modperl_util.h11 Jan 2003 00:02:16 - 1.37 +++ modperl_util.h23 Jan 2003 00:31:28 - 1.38 @@ -50,6 +50,13 @@ #define MP_magical_tie(sv, mg_flags) \ SvFLAGS((SV*)sv) |= mg_flags +#
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/21 22:12:43 Modified:.Changes t/response/TestModperl request_rec_tie_api.pm todo api.txt xs/Apache/RequestIO Apache__RequestIO.h xs/maps modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: OPEN and CLOSE tiehandle API + tests Revision ChangesPath 1.108 +1 -1 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.107 retrieving revision 1.108 diff -u -r1.107 -r1.108 --- Changes 22 Jan 2003 03:19:43 - 1.107 +++ Changes 22 Jan 2003 06:12:42 - 1.108 @@ -10,7 +10,7 @@ =item 1.99_09-dev -Add $r->FILENO implementation [Stas] +OPEN, CLOSE and FILENO implementation for Apache::RequestRec [Stas] Apache::Test: Support blocks in .pm files, so we can have a full manual control over generated config 1.2 +30 -2 modperl-2.0/t/response/TestModperl/request_rec_tie_api.pm Index: request_rec_tie_api.pm === RCS file: /home/cvs/modperl-2.0/t/response/TestModperl/request_rec_tie_api.pm,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- request_rec_tie_api.pm22 Jan 2003 03:19:43 - 1.1 +++ request_rec_tie_api.pm22 Jan 2003 06:12:43 - 1.2 @@ -7,15 +7,43 @@ use Apache::Test; use Apache::TestUtil; +use Apache::TestConfig; + +use File::Spec::Functions qw(catfile catdir); use Apache::Const -compile => 'OK'; sub handler { my $r = shift; -plan $r, tests => 1; +plan $r, tests => 3; + +ok fileno STDOUT; + +{ +my $vars = Apache::Test::config()->{vars}; +my $target_dir = catdir $vars->{serverroot}, 'logs'; +my $file = catfile $target_dir, "stdout"; + +# test OPEN +my $received = open STDOUT, ">", $file or die "Can't open $file: $!"; +ok t_cmp(1, $received, "OPEN"); + +# test CLOSE, which is a noop +ok $r->CLOSE; +close $file; + +# restore the tie +tie *STDOUT, $r; + +# flush things that went into the file as STDOUT +open my $fh, $file or die "Can't open $file: $!"; +local $\; +print <$fh>; -ok t_cmp(fileno(STDOUT), $r->FILENO(), "FILENO"); +# cleanup +unlink $file; +} return Apache::OK; } 1.31 +2 -1 modperl-2.0/todo/api.txt Index: api.txt === RCS file: /home/cvs/modperl-2.0/todo/api.txt,v retrieving revision 1.30 retrieving revision 1.31 diff -u -r1.30 -r1.31 --- api.txt 22 Jan 2003 03:19:43 - 1.30 +++ api.txt 22 Jan 2003 06:12:43 - 1.31 @@ -3,8 +3,9 @@ -- tied filehandle interface: - -CLOSE, OPEN, EOF, TELL, SEEK + -EOF, TELL, SEEK -READLINE - proper implementation (see comment in Apache::compat) + need to attempt to fix that interface so it'll work with IPC::Open* family $r->finfo: need apr_finfo_t <-> struct stat conversion (might already be there, 1.32 +24 -0 modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h Index: Apache__RequestIO.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h,v retrieving revision 1.31 retrieving revision 1.32 diff -u -r1.31 -r1.32 --- Apache__RequestIO.h 22 Jan 2003 03:19:43 - 1.31 +++ Apache__RequestIO.h 22 Jan 2003 06:12:43 - 1.32 @@ -14,6 +14,8 @@ #define mpxs_Apache__RequestRec_PRINTF mpxs_ap_rprintf #define mpxs_Apache__RequestRec_BINMODE(r) \ r ? SVYES : SVNO /* noop */ +#define mpxs_Apache__RequestRec_CLOSE(r) \ +r ? SVYES : SVNO /* noop */ #define mpxs_Apache__RequestRec_UNTIE(r, refcnt) \ (r && refcnt) ? SVYES : SVNO /* noop */ @@ -234,6 +236,28 @@ } return &PL_sv_undef; +} + +static MP_INLINE +int mpxs_Apache__RequestRec_OPEN(pTHX_ SV *self, SV *arg1, SV *arg2) +{ +char *name; +STRLEN len; +SV *arg; +dHANDLE("STDOUT"); + +modperl_io_handle_untie(aTHX_ handle); /* untie *STDOUT */ + +if (arg2 && self) { +arg = newSVsv(arg1); +sv_catsv(arg, arg2); +} +else { +arg = arg1; +} + +name = SvPV(arg, len); +return do_open(handle, name, len, FALSE, O_RDONLY, 0, Nullfp); } static MP_INLINE 1.50 +2 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map ===
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/21 19:19:43 Modified:.Changes src/modules/perl modperl_io.c modperl_io.h t/modperl .cvsignore todo api.txt xs/Apache/RequestIO Apache__RequestIO.h xs/maps modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Added: t/response/TestModperl request_rec_tie_api.pm Log: - expose useful macros from modperl_io.c via modperl_io.h - add $r->FILENO implementation - add a test Revision ChangesPath 1.107 +2 -0 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.106 retrieving revision 1.107 diff -u -r1.106 -r1.107 --- Changes 20 Jan 2003 07:54:52 - 1.106 +++ Changes 22 Jan 2003 03:19:43 - 1.107 @@ -10,6 +10,8 @@ =item 1.99_09-dev +Add $r->FILENO implementation [Stas] + Apache::Test: Support blocks in .pm files, so we can have a full manual control over generated config sections. These sections are fully parsed and variables are 1.1 modperl-2.0/t/response/TestModperl/request_rec_tie_api.pm Index: request_rec_tie_api.pm === package TestModperl::request_rec_tie_api; use strict; use warnings FATAL => 'all'; use Apache::RequestIO (); use Apache::Test; use Apache::TestUtil; use Apache::Const -compile => 'OK'; sub handler { my $r = shift; plan $r, tests => 1; ok t_cmp(fileno(STDOUT), $r->FILENO(), "FILENO"); return Apache::OK; } 1; 1.9 +0 -13 modperl-2.0/src/modules/perl/modperl_io.c Index: modperl_io.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_io.c,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- modperl_io.c 24 Mar 2002 02:41:29 - 1.8 +++ modperl_io.c 22 Jan 2003 03:19:43 - 1.9 @@ -1,18 +1,5 @@ #include "mod_perl.h" -/* - * bleedperl change #11639 switch tied handle magic - * from living in the gv to the GvIOp(gv), so we have to deal - * with both to support 5.6.x - */ -#if ((PERL_REVISION == 5) && (PERL_VERSION >= 7)) -# define TIEHANDLE_SV(handle) (SV*)GvIOp((SV*)handle) -#else -# define TIEHANDLE_SV(handle) (SV*)handle -#endif - -#define dHANDLE(name) GV *handle = gv_fetchpv(name, TRUE, SVt_PVIO) - #define TIEHANDLE(handle,r) \ modperl_io_handle_tie(aTHX_ handle, "Apache::RequestRec", (void *)r) 1.2 +13 -0 modperl-2.0/src/modules/perl/modperl_io.h Index: modperl_io.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_io.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- modperl_io.h 5 May 2001 22:06:41 - 1.1 +++ modperl_io.h 22 Jan 2003 03:19:43 - 1.2 @@ -1,6 +1,19 @@ #ifndef MODPERL_IO_H #define MODPERL_IO_H +/* + * bleedperl change #11639 switch tied handle magic + * from living in the gv to the GvIOp(gv), so we have to deal + * with both to support 5.6.x + */ +#if ((PERL_REVISION == 5) && (PERL_VERSION >= 7)) +# define TIEHANDLE_SV(handle) (SV*)GvIOp((SV*)handle) +#else +# define TIEHANDLE_SV(handle) (SV*)handle +#endif + +#define dHANDLE(name) GV *handle = gv_fetchpv(name, TRUE, SVt_PVIO) + #define IoFLUSH_off(gv) \ IoFLAGS(GvIOp((gv))) &= ~IOf_FLUSH 1.11 +1 -0 modperl-2.0/t/modperl/.cvsignore Index: .cvsignore === RCS file: /home/cvs/modperl-2.0/t/modperl/.cvsignore,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- .cvsignore22 Oct 2002 15:13:22 - 1.10 +++ .cvsignore22 Jan 2003 03:19:43 - 1.11 @@ -10,3 +10,4 @@ methodobj.t method.t setauth.t +request_rec_tie_api.t 1.30 +1 -1 modperl-2.0/todo/api.txt Index: api.txt === RCS file: /home/cvs/modperl-2.0/todo/api.txt,v retrieving revision 1.29 retrieving revision 1.30 diff -u -r1.29 -r1.30 --- api.txt 6 Dec 2002 16:19:36 - 1.29 +++ api.txt 22 Jan 2003 03:19:43 - 1.30 @@ -3,7 +3,7 @@ -- tied filehandle interface: - -CLOSE, OPEN, EOF, TELL, SEEK, FILENO + -CLOSE, OPEN, EOF, TELL, SEEK -READLINE - proper implementation (see comment in Apache::compat) $r->finfo: 1.31 +7 -0 modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/16 19:08:31 Modified:src/modules/perl modperl_filter.c modperl_filter.h .Changes xs modperl_xs_util.h xs/Apache/RequestIO Apache__RequestIO.h xs/tables/current/ModPerl FunctionTable.pm Log: prevent segfault in $r->print / $filter->print (in output filter) and related functions when they are called before the response phase Revision ChangesPath 1.44 +11 -4 modperl-2.0/src/modules/perl/modperl_filter.c Index: modperl_filter.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.c,v retrieving revision 1.43 retrieving revision 1.44 diff -u -r1.43 -r1.44 --- modperl_filter.c 15 Jan 2003 06:07:10 - 1.43 +++ modperl_filter.c 17 Jan 2003 03:08:31 - 1.44 @@ -55,13 +55,18 @@ return rv; } -MP_INLINE apr_status_t modperl_wbucket_write(modperl_wbucket_t *wb, +MP_INLINE apr_status_t modperl_wbucket_write(pTHX_ modperl_wbucket_t *wb, const char *buf, apr_size_t *wlen) { apr_size_t len = *wlen; *wlen = 0; +if (!wb) { +/* the response is not initialized yet */ +Perl_croak(aTHX_ "can't be called before the response phase"); +} + if ((len + wb->outcnt) > sizeof(wb->outbuf)) { apr_status_t rv; if ((rv = modperl_wbucket_flush(wb)) != APR_SUCCESS) { @@ -505,7 +510,8 @@ return filter->rc; } -MP_INLINE apr_status_t modperl_input_filter_write(modperl_filter_t *filter, +MP_INLINE apr_status_t modperl_input_filter_write(pTHX_ + modperl_filter_t *filter, const char *buf, apr_size_t *len) { @@ -519,11 +525,12 @@ return APR_SUCCESS; } -MP_INLINE apr_status_t modperl_output_filter_write(modperl_filter_t *filter, +MP_INLINE apr_status_t modperl_output_filter_write(pTHX_ + modperl_filter_t *filter, const char *buf, apr_size_t *len) { -return modperl_wbucket_write(&filter->wbucket, buf, len); +return modperl_wbucket_write(aTHX_ &filter->wbucket, buf, len); } apr_status_t modperl_output_filter_handler(ap_filter_t *f, 1.17 +6 -3 modperl-2.0/src/modules/perl/modperl_filter.h Index: modperl_filter.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.h,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- modperl_filter.h 15 Jan 2003 06:07:10 - 1.16 +++ modperl_filter.h 17 Jan 2003 03:08:31 - 1.17 @@ -16,7 +16,8 @@ MP_INLINE apr_status_t modperl_wbucket_flush(modperl_wbucket_t *b); -MP_INLINE apr_status_t modperl_wbucket_write(modperl_wbucket_t *b, +MP_INLINE apr_status_t modperl_wbucket_write(pTHX_ + modperl_wbucket_t *b, const char *buf, apr_size_t *wlen); @@ -50,7 +51,8 @@ SV *buffer, apr_size_t wanted); -MP_INLINE apr_status_t modperl_output_filter_write(modperl_filter_t *filter, +MP_INLINE apr_status_t modperl_output_filter_write(pTHX_ + modperl_filter_t *filter, const char *buf, apr_size_t *len); @@ -75,7 +77,8 @@ SV *buffer, apr_size_t wanted); -MP_INLINE apr_status_t modperl_input_filter_write(modperl_filter_t *filter, +MP_INLINE apr_status_t modperl_input_filter_write(pTHX_ + modperl_filter_t *filter, const char *buf, apr_size_t *len); 1.103 +5 -2 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.102 retrieving revision 1.103 diff -u -r1.102 -r1.103 --- Changes 17 Jan 2003 02:26:31 - 1.102 +++ Changes 17 Jan 2003 03:08:31 - 1.103 @@ -10,8 +10,11 @@ =item 1.99_09-dev
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/16 18:26:32 Modified:.Changes xs/Apache/Response Apache__Response.h xs/tables/current/ModPerl FunctionTable.pm Log: fix segfault in send_http_header when it's called before the response phase Revision ChangesPath 1.102 +3 -0 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.101 retrieving revision 1.102 diff -u -r1.101 -r1.102 --- Changes 16 Jan 2003 02:38:09 - 1.101 +++ Changes 17 Jan 2003 02:26:31 - 1.102 @@ -10,6 +10,9 @@ =item 1.99_09-dev +fix segfault in send_http_header when it's called before the response +phase [Stas] + input stream filtering support was added + tests (plus renaming filter tests so we can know from the test name what kind of filter is tested) [Stas] 1.8 +11 -2 modperl-2.0/xs/Apache/Response/Apache__Response.h Index: Apache__Response.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Response/Apache__Response.h,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- Apache__Response.h19 May 2002 23:01:12 - 1.7 +++ Apache__Response.h17 Jan 2003 02:26:31 - 1.8 @@ -15,7 +15,8 @@ /* XXX: should only be part of Apache::compat */ static MP_INLINE void -mpxs_Apache__RequestRec_send_http_header(request_rec *r, const char *type) +mpxs_Apache__RequestRec_send_http_header(pTHX_ request_rec *r, + const char *type) { MP_dRCFG; @@ -23,7 +24,15 @@ ap_set_content_type(r, apr_pstrdup(r->pool, type)); } -rcfg->wbucket->header_parse = 0; /* turn off PerlOptions +ParseHeaders */ +if (rcfg->wbucket) { +/* turn off PerlOptions +ParseHeaders */ +rcfg->wbucket->header_parse = 0; +} +else { +/* the response is not initialized yet */ +Perl_croak(aTHX_ "send_http_header() can't be called before " + "the response phase"); +} } static MP_INLINE void 1.95 +4 -0 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.94 retrieving revision 1.95 diff -u -r1.94 -r1.95 --- FunctionTable.pm 15 Jan 2003 06:07:10 - 1.94 +++ FunctionTable.pm 17 Jan 2003 02:26:32 - 1.95 @@ -5370,6 +5370,10 @@ 'name' => 'mpxs_Apache__RequestRec_send_http_header', 'args' => [ { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { 'type' => 'request_rec *', 'name' => 'r' },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/14 22:07:11 Modified:src/modules/perl modperl_filter.c modperl_filter.h modperl_types.h xs/tables/current/ModPerl FunctionTable.pm Log: - implementation of the input stream filtering support (1st phase) - code refactoring to be re-use for input and output filtering - proper support for mis-behaved feeding filters that send more than one EOS bucket Revision ChangesPath 1.43 +225 -66 modperl-2.0/src/modules/perl/modperl_filter.c Index: modperl_filter.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.c,v retrieving revision 1.42 retrieving revision 1.43 diff -u -r1.42 -r1.43 --- modperl_filter.c 12 Jan 2003 02:21:37 - 1.42 +++ modperl_filter.c 15 Jan 2003 06:07:10 - 1.43 @@ -94,15 +94,23 @@ filter->mode = mode; filter->f = f; -filter->bb = bb; filter->pool = p; filter->wbucket.pool = p; filter->wbucket.filters = &f->next; filter->wbucket.outcnt = 0; +if (mode == MP_INPUT_FILTER_MODE) { +filter->bb_in = NULL; +filter->bb_out = bb; +} +else { +filter->bb_in = bb; +filter->bb_out = NULL; +} + MP_TRACE_f(MP_FUNC, "filter=0x%lx, mode=%s\n", - (unsigned long)filter, mode == MP_OUTPUT_FILTER_MODE ? - "output" : "input"); + (unsigned long)filter, + mode == MP_INPUT_FILTER_MODE ? "input" : "output"); return filter; } @@ -138,7 +146,10 @@ modperl_handler_make_args(aTHX_ &args, "Apache::Filter", filter->f, - "APR::Brigade", filter->bb, + "APR::Brigade", + (filter->mode == MP_INPUT_FILTER_MODE + ? filter->bb_out + : filter->bb_in), NULL); modperl_filter_mg_set(aTHX_ AvARRAY(args)[0], filter); @@ -168,26 +179,59 @@ filter->seen_eos = 0; } -if (filter->mode == MP_OUTPUT_FILTER_MODE) { +if (filter->mode == MP_INPUT_FILTER_MODE) { +if (filter->bb_in) { +/* in the streaming mode filter->bb_in is populated on the + * first modperl_input_filter_read, so it must be + * destroyed at the end of the filter invocation + */ +/* XXX: may be the filter must consume all the data? add a + * test to check */ +apr_brigade_destroy(filter->bb_in); +filter->bb_in = NULL; +} +modperl_input_filter_flush(filter); +} +else { modperl_output_filter_flush(filter); } + return status; } /* output filters */ -MP_INLINE static apr_status_t send_eos(ap_filter_t *f) +MP_INLINE static apr_status_t send_input_eos(modperl_filter_t *filter) +{ +apr_bucket_alloc_t *ba = filter->f->c->bucket_alloc; +apr_bucket *b = apr_bucket_eos_create(ba); +APR_BRIGADE_INSERT_TAIL(filter->bb_out, b); +((modperl_filter_ctx_t *)filter->f->ctx)->sent_eos = 1; +return APR_SUCCESS; + +} + +MP_INLINE static apr_status_t send_input_flush(modperl_filter_t *filter) +{ +apr_bucket_alloc_t *ba = filter->f->c->bucket_alloc; +apr_bucket *b = apr_bucket_flush_create(ba); +APR_BRIGADE_INSERT_TAIL(filter->bb_out, b); +return APR_SUCCESS; +} + +MP_INLINE static apr_status_t send_output_eos(ap_filter_t *f) { apr_bucket_alloc_t *ba = f->c->bucket_alloc; apr_bucket_brigade *bb = apr_brigade_create(MP_FILTER_POOL(f), ba); apr_bucket *b = apr_bucket_eos_create(ba); APR_BRIGADE_INSERT_TAIL(bb, b); +((modperl_filter_ctx_t *)f->ctx)->sent_eos = 1; return ap_pass_brigade(f->next, bb); } -MP_INLINE static apr_status_t send_flush(ap_filter_t *f) +MP_INLINE static apr_status_t send_output_flush(ap_filter_t *f) { apr_bucket_alloc_t *ba = f->c->bucket_alloc; apr_bucket_brigade *bb = apr_brigade_create(MP_FILTER_POOL(f), @@ -199,11 +243,14 @@ /* unrolled APR_BRIGADE_FOREACH loop */ +#define MP_FILTER_EMPTY(filter) \ +APR_BRIGADE_EMPTY(filter->bb_in) + #define MP_FILTER_SENTINEL(filter) \ -APR_BRIGADE_SENTINEL(filter->bb) +APR_BRIGADE_SENTINEL(filter->bb_in) #define MP_FILTER_FIRST(filter) \ -APR_BRIGADE_FIRST(filter->bb) +APR_BRIGADE_FIRST(filter->bb_in) #define MP_FILTER_NEXT(filter) \ APR_BUCKET_NEXT(filter->bucket) @@ -216,52 +263,83 @@ MP_INLINE static int get_bucket(modperl_filter_t *filter) { -if (!filter->bb) { +if (!filter->bb_in
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/11 18:33:28 Modified:xs/Apache/Filter Apache__Filter.h xs/maps modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: add $filter->seen_eos flag for the streaming interface Revision ChangesPath 1.21 +8 -0 modperl-2.0/xs/Apache/Filter/Apache__Filter.h Index: Apache__Filter.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Filter/Apache__Filter.h,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- Apache__Filter.h 12 Jan 2003 02:31:54 - 1.20 +++ Apache__Filter.h 12 Jan 2003 02:33:27 - 1.21 @@ -125,3 +125,11 @@ return ctx->data ? SvREFCNT_inc(ctx->data) : &PL_sv_undef; } + +static MP_INLINE SV *mpxs_Apache__Filter_seen_eos(pTHX_ I32 items, + SV **MARK, SV **SP) +{ +modperl_filter_t *modperl_filter; +mpxs_usage_va_1(modperl_filter, "$filter->seen_eos()"); +return modperl_filter->seen_eos ? &PL_sv_yes : &PL_sv_no; +} 1.48 +1 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.47 retrieving revision 1.48 diff -u -r1.47 -r1.48 --- modperl_functions.map 12 Jan 2003 02:31:54 - 1.47 +++ modperl_functions.map 12 Jan 2003 02:33:27 - 1.48 @@ -74,6 +74,7 @@ mpxs_Apache__Filter_print | | ... mpxs_Apache__Filter_read | | ... + mpxs_Apache__Filter_seen_eos | | ... mpxs_Apache__Filter_ctx | | filter, data=Nullsv SV *:DEFINE_TIEHANDLE | | SV *:stashsv, SV *:sv=Nullsv 1.93 +26 -0 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.92 retrieving revision 1.93 diff -u -r1.92 -r1.93 --- FunctionTable.pm 12 Jan 2003 02:31:55 - 1.92 +++ FunctionTable.pm 12 Jan 2003 02:33:28 - 1.93 @@ -4892,6 +4892,32 @@ ] }, { +'return_type' => 'SV *', +'name' => 'mpxs_Apache__Filter_seen_eos', +'attr' => [ + 'static', + '__inline__' +], +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'I32', +'name' => 'items' + }, + { +'type' => 'SV **', +'name' => 'mark' + }, + { +'type' => 'SV **', +'name' => 'sp' + } +] + }, + { 'return_type' => 'void', 'name' => 'mpxs_Apache__Log_BOOT', 'attr' => [
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2003/01/11 18:31:55 Modified:xs/Apache/Filter Apache__Filter.h xs/maps apache_structures.map modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: add support for filter context variable Revision ChangesPath 1.20 +13 -0 modperl-2.0/xs/Apache/Filter/Apache__Filter.h Index: Apache__Filter.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Filter/Apache__Filter.h,v retrieving revision 1.19 retrieving revision 1.20 diff -u -r1.19 -r1.20 --- Apache__Filter.h 1 Jul 2002 07:08:45 - 1.19 +++ Apache__Filter.h 12 Jan 2003 02:31:54 - 1.20 @@ -112,3 +112,16 @@ XSRETURN_EMPTY; } + +static MP_INLINE SV *mpxs_Apache__Filter_ctx(pTHX_ + ap_filter_t *filter, + SV *data) +{ +modperl_filter_ctx_t *ctx = (modperl_filter_ctx_t *)(filter->ctx); + +if (data != Nullsv) { +ctx->data = SvREFCNT_inc(data); +} + +return ctx->data ? SvREFCNT_inc(ctx->data) : &PL_sv_undef; +} 1.18 +1 -1 modperl-2.0/xs/maps/apache_structures.map Index: apache_structures.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apache_structures.map,v retrieving revision 1.17 retrieving revision 1.18 diff -u -r1.17 -r1.18 --- apache_structures.map 21 May 2002 02:50:16 - 1.17 +++ apache_structures.map 12 Jan 2003 02:31:54 - 1.18 @@ -170,7 +170,7 @@ frec - ctx +- ctx next r c 1.47 +1 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.46 retrieving revision 1.47 diff -u -r1.46 -r1.47 --- modperl_functions.map 6 Dec 2002 16:19:36 - 1.46 +++ modperl_functions.map 12 Jan 2003 02:31:54 - 1.47 @@ -74,6 +74,7 @@ mpxs_Apache__Filter_print | | ... mpxs_Apache__Filter_read | | ... + mpxs_Apache__Filter_ctx | | filter, data=Nullsv SV *:DEFINE_TIEHANDLE | | SV *:stashsv, SV *:sv=Nullsv int:DEFINE_PRINT | | ... 1.92 +22 -0 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.91 retrieving revision 1.92 diff -u -r1.91 -r1.92 --- FunctionTable.pm 12 Jan 2003 02:15:58 - 1.91 +++ FunctionTable.pm 12 Jan 2003 02:31:55 - 1.92 @@ -4870,6 +4870,28 @@ ] }, { +'return_type' => 'SV *', +'name' => 'mpxs_Apache__Filter_ctx', +'attr' => [ + 'static', + '__inline__' +], +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'ap_filter_t *', +'name' => 'filter' + }, + { +'type' => 'SV *', +'name' => 'data' + }, +] + }, + { 'return_type' => 'void', 'name' => 'mpxs_Apache__Log_BOOT', 'attr' => [
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2003/01/10 16:02:17 Modified:src/modules/perl modperl_util.c modperl_util.h xs/Apache/RequestUtil Apache__RequestUtil.h xs/tables/current/ModPerl FunctionTable.pm Log: sv_str_header needs to be passed the current aTHX to avoid a pile of calls to the expensive dTHX; in $r->as_string. also needed to s/sv_catpvf/Perl_sv_catpvf for the -DPERL_CORE optimization. have made sv_str_header private to Apache__RequestUtil.h in the process, as the usage is ugly with THX; can re-{think,expose} later if it turns out to be needed elsewhere. Revision ChangesPath 1.50 +0 -7 modperl-2.0/src/modules/perl/modperl_util.c Index: modperl_util.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_util.c,v retrieving revision 1.49 retrieving revision 1.50 diff -u -r1.49 -r1.50 --- modperl_util.c6 Dec 2002 16:19:36 - 1.49 +++ modperl_util.c11 Jan 2003 00:02:16 - 1.50 @@ -615,10 +615,3 @@ return rv; } -int modperl_sv_str_header(void *arg, const char *k, const char *v) -{ -SV *sv = (SV*)arg; -sv_catpvf(sv, "%s: %s\n", k, v); -return 1; -} - 1.37 +0 -2 modperl-2.0/src/modules/perl/modperl_util.h Index: modperl_util.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_util.h,v retrieving revision 1.36 retrieving revision 1.37 diff -u -r1.36 -r1.37 --- modperl_util.h6 Dec 2002 16:19:36 - 1.36 +++ modperl_util.h11 Jan 2003 00:02:16 - 1.37 @@ -118,7 +118,5 @@ MP_INLINE int modperl_perl_module_loaded(pTHX_ const char *name); SV *modperl_perl_gensym(pTHX_ char *pack); - -int modperl_sv_str_header(void *arg, const char *k, const char *v); #endif /* MODPERL_UTIL_H */ 1.15 +26 -8 modperl-2.0/xs/Apache/RequestUtil/Apache__RequestUtil.h Index: Apache__RequestUtil.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestUtil/Apache__RequestUtil.h,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- Apache__RequestUtil.h 10 Jan 2003 23:32:33 - 1.14 +++ Apache__RequestUtil.h 11 Jan 2003 00:02:16 - 1.15 @@ -215,25 +215,43 @@ return dcfg->location; } +typedef struct { +PerlInterpreter *perl; +SV *sv; +} sv_str_header_t; + +static int sv_str_header(void *arg, const char *k, const char *v) +{ +sv_str_header_t *svh = (sv_str_header_t *)arg; +dTHXa(svh->perl); +Perl_sv_catpvf(aTHX_ svh->sv, "%s: %s\n", k, v); +return 1; +} + static MP_INLINE SV *mpxs_Apache__RequestRec_as_string(pTHX_ request_rec *r) { -SV *retval = newSVpv(r->the_request, 0); +sv_str_header_t svh; +#ifdef USE_ITHREADS +svh.perl = aTHX; +#endif + +svh.sv = newSVpv(r->the_request, 0); -sv_catpvn(retval, "\n", 1); +sv_catpvn(svh.sv, "\n", 1); apr_table_do((int (*) (void *, const char *, const char *)) - modperl_sv_str_header, (void *) retval, r->headers_in, NULL); + sv_str_header, (void *) &svh, r->headers_in, NULL); -Perl_sv_catpvf(aTHX_ retval, "\n%s %s\n", r->protocol, r->status_line); +Perl_sv_catpvf(aTHX_ svh.sv, "\n%s %s\n", r->protocol, r->status_line); apr_table_do((int (*) (void *, const char *, const char *)) - modperl_sv_str_header, (void *) retval, r->headers_out, NULL); + sv_str_header, (void *) &svh, r->headers_out, NULL); apr_table_do((int (*) (void *, const char *, const char *)) - modperl_sv_str_header, (void *) retval, r->err_headers_out, NULL); + sv_str_header, (void *) &svh, r->err_headers_out, NULL); -sv_catpvn(retval, "\n", 1); +sv_catpvn(svh.sv, "\n", 1); -return retval; +return svh.sv; } 1.90 +0 -18 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.89 retrieving revision 1.90 diff -u -r1.89 -r1.90 --- FunctionTable.pm 12 Dec 2002 10:05:08 - 1.89 +++ FunctionTable.pm 11 Jan 2003 00:02:16 - 1.90 @@ -3831,24 +3831,6 @@ ] }, { -'return_type' => 'int', -'name' => 'modperl_sv_str_header', -'args' => [ - { -'type' => 'void *', -'name' => 'arg' - }, - { -'type' => 'const char *', -'name' => 'k' - }, - { -'type' => 'const char *', -
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2002/12/12 02:05:08 Modified:src/modules/perl mod_perl.c mod_perl.h modperl_config.c xs/tables/current/ModPerl FunctionTable.pm Log: make mod_perl work with vhosts when the server is started prior to post_config(): - call modperl_init_globals as early as possible, because the main server record is needed during the configuration parsing, for perlloadmodule and vhosts - also make sure that we are using a real base_server, when dealing with modperl_init, and if not retrieve it from the global record Revision ChangesPath 1.145 +19 -3 modperl-2.0/src/modules/perl/mod_perl.c Index: mod_perl.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/mod_perl.c,v retrieving revision 1.144 retrieving revision 1.145 diff -u -r1.144 -r1.145 --- mod_perl.c23 Nov 2002 22:56:21 - 1.144 +++ mod_perl.c12 Dec 2002 10:05:07 - 1.145 @@ -279,9 +279,25 @@ void modperl_init(server_rec *base_server, apr_pool_t *p) { server_rec *s; -modperl_config_srv_t *base_scfg = modperl_config_srv_get(base_server); +modperl_config_srv_t *base_scfg; PerlInterpreter *base_perl; +/* get the real base server when invoked from vhost. + * + * without doing it segfaults when the first PerlLoadModule + * appears inside vhost, e.g.: + * + * PerlLoadModule Foo + * + * an arrangement which is unfortunately hard to automate with our + * test suite, but see test TestDirective::perlloadmodule6 + */ +if (base_server->is_virtual) { +base_server = modperl_global_get_server_rec(); +} + +base_scfg = modperl_config_srv_get(base_server); + MP_TRACE_d_do(MpSrv_dump_flags(base_scfg, base_server->server_hostname)); @@ -359,7 +375,7 @@ } #endif /* USE_ITHREADS */ -static void modperl_init_globals(server_rec *s, apr_pool_t *pconf) +void modperl_init_globals(server_rec *s, apr_pool_t *pconf) { int threaded_mpm; ap_mpm_query(AP_MPMQ_IS_THREADED, &threaded_mpm); @@ -428,7 +444,7 @@ modperl_sys_init(); apr_pool_cleanup_register(pconf, NULL, modperl_sys_term, apr_pool_cleanup_null); -modperl_init_globals(s, pconf); + modperl_init(s, pconf); return OK; 1.55 +1 -0 modperl-2.0/src/modules/perl/mod_perl.h Index: mod_perl.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/mod_perl.h,v retrieving revision 1.54 retrieving revision 1.55 diff -u -r1.54 -r1.55 --- mod_perl.h15 Sep 2002 23:30:06 - 1.54 +++ mod_perl.h12 Dec 2002 10:05:08 - 1.55 @@ -74,6 +74,7 @@ int modperl_init_vhost(server_rec *s, apr_pool_t *p, server_rec *base_server); void modperl_init(server_rec *s, apr_pool_t *p); +void modperl_init_globals(server_rec *s, apr_pool_t *pconf); int modperl_run(apr_pool_t *p, server_rec *s); int modperl_is_running(void); int modperl_hook_init(apr_pool_t *pconf, apr_pool_t *plog, 1.60 +12 -3 modperl-2.0/src/modules/perl/modperl_config.c Index: modperl_config.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_config.c,v retrieving revision 1.59 retrieving revision 1.60 diff -u -r1.59 -r1.60 --- modperl_config.c 9 Dec 2002 07:28:02 - 1.59 +++ modperl_config.c 12 Dec 2002 10:05:08 - 1.60 @@ -164,10 +164,19 @@ ap_mpm_query(AP_MPMQ_IS_THREADED, &scfg->threaded_mpm); -/* give a chance to MOD_PERL_TRACE env var to set PerlTrace. This - * place is the earliest point in mod_perl configuration - * parsing, when we have the server object */ if (!s->is_virtual) { + +/* Must store the global server record as early as possible, + * because if mod_perl happens to be started from within a + * vhost (e.g., PerlLoadModule) the base server record won't + * be availalbe to vhost and things will blow up + */ +modperl_init_globals(s, p); + +/* give a chance to MOD_PERL_TRACE env var to set + * PerlTrace. This place is the earliest point in mod_perl + * configuration parsing, when we have the server object + */ modperl_trace_level_set(s, NULL); } 1.89 +14 -0 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.88
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2002/12/07 17:57:49 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: The recent addition of $r->as_string requiring modperl_sv_str_header requires, at least for Win32, adding this function to ModPerl::FunctionTable so that it gets included in the mod_perl lib. Submitted by: Randy Kobes <[EMAIL PROTECTED]> Reviewed by: stas Revision ChangesPath 1.88 +18 -0 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.87 retrieving revision 1.88 diff -u -r1.87 -r1.88 --- FunctionTable.pm 6 Dec 2002 16:19:36 - 1.87 +++ FunctionTable.pm 8 Dec 2002 01:57:49 - 1.88 @@ -3817,6 +3817,24 @@ ] }, { +'return_type' => 'int', +'name' => 'modperl_sv_str_header', +'args' => [ + { +'type' => 'void *', +'name' => 'arg' + }, + { +'type' => 'const char *', +'name' => 'k' + }, + { +'type' => 'const char *', +'name' => 'v' + }, +] + }, + { 'return_type' => 'apr_pool_t *', 'name' => 'modperl_sv2pool', 'args' => [
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
geoff 2002/12/06 08:19:37 Modified:src/modules/perl modperl_util.c modperl_util.h t/response/TestAPI rutil.pm todo api.txt xs/Apache/RequestUtil Apache__RequestUtil.h xs/maps modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: added $r->as_string Submitted by: geoff Reviewed by: stas Revision ChangesPath 1.49 +8 -0 modperl-2.0/src/modules/perl/modperl_util.c Index: modperl_util.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_util.c,v retrieving revision 1.48 retrieving revision 1.49 diff -u -r1.48 -r1.49 --- modperl_util.c1 Jul 2002 05:15:28 - 1.48 +++ modperl_util.c6 Dec 2002 16:19:36 - 1.49 @@ -614,3 +614,11 @@ GvNAME(gv), GvNAMELEN(gv), G_DISCARD); return rv; } + +int modperl_sv_str_header(void *arg, const char *k, const char *v) +{ +SV *sv = (SV*)arg; +sv_catpvf(sv, "%s: %s\n", k, v); +return 1; +} + 1.36 +2 -0 modperl-2.0/src/modules/perl/modperl_util.h Index: modperl_util.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_util.h,v retrieving revision 1.35 retrieving revision 1.36 diff -u -r1.35 -r1.36 --- modperl_util.h21 Jun 2002 00:44:24 - 1.35 +++ modperl_util.h6 Dec 2002 16:19:36 - 1.36 @@ -119,4 +119,6 @@ SV *modperl_perl_gensym(pTHX_ char *pack); +int modperl_sv_str_header(void *arg, const char *k, const char *v); + #endif /* MODPERL_UTIL_H */ 1.4 +6 -1 modperl-2.0/t/response/TestAPI/rutil.pm Index: rutil.pm === RCS file: /home/cvs/modperl-2.0/t/response/TestAPI/rutil.pm,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- rutil.pm 11 Apr 2002 11:08:43 - 1.3 +++ rutil.pm 6 Dec 2002 16:19:36 - 1.4 @@ -30,7 +30,7 @@ sub handler { my $r = shift; -plan $r, tests => 17; +plan $r, tests => 18; ok $r->default_type; @@ -53,6 +53,11 @@ } ok $r->is_initial_req; + +# test for the request_line, status_ling, and few +# headers that should always be there +ok $r->as_string =~ +m!GET /TestAPI::rutil.*Host:.*200 OK.*Content-Type:!s; Apache::OK; } 1.29 +0 -3 modperl-2.0/todo/api.txt Index: api.txt === RCS file: /home/cvs/modperl-2.0/todo/api.txt,v retrieving revision 1.28 retrieving revision 1.29 diff -u -r1.28 -r1.29 --- api.txt 22 Oct 2002 15:13:22 - 1.28 +++ api.txt 6 Dec 2002 16:19:36 - 1.29 @@ -53,9 +53,6 @@ with fd's which aren't files and of unknown length, therefore it cannot be used for implementing 1.x compatible send_fd. -$r->as_string: -not yet implemented - Apache::{Server,Process} classes: require mutex lock for writing 1.13 +23 -0 modperl-2.0/xs/Apache/RequestUtil/Apache__RequestUtil.h Index: Apache__RequestUtil.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestUtil/Apache__RequestUtil.h,v retrieving revision 1.12 retrieving revision 1.13 diff -u -r1.12 -r1.13 --- Apache__RequestUtil.h 5 Dec 2001 19:00:29 - 1.12 +++ Apache__RequestUtil.h 6 Dec 2002 16:19:36 - 1.13 @@ -214,3 +214,26 @@ return dcfg->location; } + +static MP_INLINE +SV *mpxs_Apache__RequestRec_as_string(pTHX_ request_rec *r) +{ +SV *retval = newSVpv(r->the_request, 0); + +sv_catpvn(retval, "\n", 1); + +apr_table_do((int (*) (void *, const char *, const char *)) + modperl_sv_str_header, (void *) retval, r->headers_in, NULL); + +sv_catpvf(retval, "\n%s %s\n", r->protocol, r->status_line); + +apr_table_do((int (*) (void *, const char *, const char *)) + modperl_sv_str_header, (void *) retval, r->headers_out, NULL); +apr_table_do((int (*) (void *, const char *, const char *)) + modperl_sv_str_header, (void *) retval, r->err_headers_out, NULL); + +sv_catpvn(retval, "\n", 1); + +return retval; +} + 1.46 +1 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.45 retrieving revision 1.46 diff -u -r1.45 -r1.46 --- modperl_functions.map 5 Sep 2002 01:48:40 -
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/10/21 10:58:41 Modified:.Changes t/response/TestAPI access.pm todo api.txt xs/Apache/Access Apache__Access.h xs/maps apache_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: Submitted by: gozer Reviewed by: dougm add support for setting $r->auth_name and $r->auth_type Revision ChangesPath 1.53 +3 -0 modperl-2.0/Changes Index: Changes === RCS file: /home/cvs/modperl-2.0/Changes,v retrieving revision 1.52 retrieving revision 1.53 diff -u -r1.52 -r1.53 --- Changes 7 Oct 2002 02:44:30 - 1.52 +++ Changes 21 Oct 2002 17:58:40 - 1.53 @@ -10,6 +10,9 @@ =item 1.99_08-dev +add support for setting $r->auth_name and $r->auth_type +[Philippe M. Chiasson <[EMAIL PROTECTED]>] + add Apache->httpd_conf compat method [Philippe M. Chiasson <[EMAIL PROTECTED]>] 1.4 +9 -1 modperl-2.0/t/response/TestAPI/access.pm Index: access.pm === RCS file: /home/cvs/modperl-2.0/t/response/TestAPI/access.pm,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- access.pm 11 Apr 2002 11:08:43 - 1.3 +++ access.pm 21 Oct 2002 17:58:40 - 1.4 @@ -12,7 +12,7 @@ sub handler { my $r = shift; -plan $r, tests => 8; +plan $r, tests => 10; $r->allow_methods(1, qw(GET POST)); @@ -28,7 +28,15 @@ ok $r->auth_name eq 'modperl'; +$r->auth_name('modperl_test'); +ok $r->auth_name eq 'modperl_test'; +$r->auth_name('modperl'); + ok $r->auth_type eq 'none'; + +$r->auth_type('Basic'); +ok $r->auth_type eq 'Basic'; +$r->auth_type('none'); ok !$r->some_auth_required; 1.27 +0 -3 modperl-2.0/todo/api.txt Index: api.txt === RCS file: /home/cvs/modperl-2.0/todo/api.txt,v retrieving revision 1.26 retrieving revision 1.27 diff -u -r1.26 -r1.27 --- api.txt 5 Sep 2002 01:52:26 - 1.26 +++ api.txt 21 Oct 2002 17:58:40 - 1.27 @@ -53,9 +53,6 @@ with fd's which aren't files and of unknown length, therefore it cannot be used for implementing 1.x compatible send_fd. -$r->auth_{name,type}: - are not yet writable. need wrappers to call modperl_config_insert_request - $r->get_basic_auth_pw: does not yet default AuthType and AuthName as 1.x does (should use modperl_config_insert_request to do so) 1.5 +42 -1 modperl-2.0/xs/Apache/Access/Apache__Access.h Index: Apache__Access.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Access/Apache__Access.h,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Apache__Access.h 5 May 2001 02:16:01 - 1.4 +++ Apache__Access.h 21 Oct 2002 17:58:40 - 1.5 @@ -78,4 +78,45 @@ } } - +static MP_INLINE void mpxs_insert_auth_cfg(pTHX_ request_rec *r, + char *directive, + char *val) +{ +const char *errmsg; +AV *config = newAV(); + +av_push(config, newSVpvf("%s %s", directive, val)); + +errmsg = +modperl_config_insert_request(aTHX_ r, + newRV_noinc((SV*)config), + r->filename, OR_AUTHCFG); + +if (errmsg) { +Perl_warn(aTHX_ "Can't change %s to '%s'\n", directive, val); +} + +SvREFCNT_dec((SV*)config); +} + +static MP_INLINE +const char *mpxs_Apache__RequestRec_auth_type(pTHX_ request_rec *r, + char *type) +{ +if (type) { +mpxs_insert_auth_cfg(aTHX_ r, "AuthType", type); +} + +return ap_auth_type(r); +} + +static MP_INLINE +const char *mpxs_Apache__RequestRec_auth_name(pTHX_ request_rec *r, + char *name) +{ +if (name) { +mpxs_insert_auth_cfg(aTHX_ r, "AuthName", name); +} + +return ap_auth_name(r); +} 1.59 +2 -2 modperl-2.0/xs/maps/apache_functions.map Index: apache_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apache_functions.map,v retrieving revision 1.58 retrieving revision 1.59 diff -u -r1.58 -r1.59 --- apache_functions.map 27 Aug 2002 04:28:38 - 1.58 +++ apache_functions.map 21 Oct 2002 17:58:40 - 1.59
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/09/04 18:49:09 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.85 +191 -31 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.84 retrieving revision 1.85 diff -u -r1.84 -r1.85 --- FunctionTable.pm 28 Aug 2002 03:16:31 - 1.84 +++ FunctionTable.pm 5 Sep 2002 01:49:08 - 1.85 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Tue Aug 27 20:02:39 2002 +# ! Wed Sep 4 18:20:53 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -1149,6 +1149,88 @@ ] }, { +'return_type' => 'const char *', +'name' => 'modperl_config_insert', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'server_rec *', +'name' => 's' + }, + { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + { +'type' => 'apr_pool_t *', +'name' => 'ptmp' + }, + { +'type' => 'int', +'name' => 'override' + }, + { +'type' => 'char *', +'name' => 'path' + }, + { +'type' => 'ap_conf_vector_t *', +'name' => 'conf' + }, + { +'type' => 'SV *', +'name' => 'lines' + } +] + }, + { +'return_type' => 'const char *', +'name' => 'modperl_config_insert_request', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'request_rec *', +'name' => 'r' + }, + { +'type' => 'SV *', +'name' => 'lines' + }, + { +'type' => 'char *', +'name' => 'path' + }, + { +'type' => 'int', +'name' => 'override' + } +] + }, + { +'return_type' => 'const char *', +'name' => 'modperl_config_insert_server', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'server_rec *', +'name' => 's' + }, + { +'type' => 'SV *', +'name' => 'lines' + } +] + }, + { 'return_type' => 'apr_status_t', 'name' => 'modperl_config_req_cleanup', 'args' => [ @@ -1239,6 +1321,68 @@ ] }, { +'return_type' => 'int', +'name' => 'modperl_const_compile', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'const char *', +'name' => 'classname' + }, + { +'type' => 'const char *', +'name' => 'arg' + }, + { +'type' => 'const char *', +'name' => 'name' + } +] + }, + { +'return_type' => 'const char **', +'name' => 'modperl_constants_group_lookup_apache', +'args' => [ + { +'type' => 'const char *', +'name' => 'name' + } +] + }, + { +'return_type' => 'const char **', +'name' => 'modperl_constants_group_lookup_apr', +'args' => [ + { +'type' => 'const char *', +'name' => 'name' + } +] + }, + { +'return_type' => 'int', +'name' => 'modperl_constants_lookup_apache', +'args' => [ + { +'type' => 'const char *', +'name' => 'name' + } +] + }, + { +'return_type' => 'int', +'name' => 'modperl_constants_lookup_apr', +'args' => [ + { +'type' => 'const char *', +'name' => 'name' + } +] + }, + { 'return_type' => 'unsigned long', 'name' => 'modperl_debug_level', 'args' => [] @@ -2680,6 +2824,26 @@ ] }, { +'return_type' => 'modperl_mgv_t *', +'name' => 'modperl_mgv_last', +'args' => [ + { +'type' => 'modperl_mgv_t *', +'name' => 'symbol' + } +] + }, + { +'return_type' => 'char *', +'name' => 'modperl_mgv_last_name', +'args' => [ + { +'type' => 'modperl_mgv_t *', +'name' => 'symbol' + } +] + }, + { 'return_type' => 'GV *', 'name' => 'modperl_mgv_lookup', 'args' => [ @@ -4640,36 +4804,6 @@ ] }, { -'return_type' => 'con
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/08/27 20:16:31 Modified:xs/tables/current/Apache FunctionTable.pm xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.40 +2 -2 modperl-2.0/xs/tables/current/Apache/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/FunctionTable.pm,v retrieving revision 1.39 retrieving revision 1.40 diff -u -r1.39 -r1.40 --- FunctionTable.pm 24 Aug 2002 17:14:39 - 1.39 +++ FunctionTable.pm 28 Aug 2002 03:16:30 - 1.40 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Sat Aug 24 09:38:51 2002 +# ! Tue Aug 27 20:02:27 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -7069,7 +7069,7 @@ ] }, { -'return_type' => 'void', +'return_type' => 'apr_status_t', 'name' => 'apr_dbm_get_usednames_ex', 'args' => [ { 1.84 +97 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.83 retrieving revision 1.84 diff -u -r1.83 -r1.84 --- FunctionTable.pm 28 Aug 2002 02:24:47 - 1.83 +++ FunctionTable.pm 28 Aug 2002 03:16:31 - 1.84 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Wed Aug 28 10:12:34 2002 +# ! Tue Aug 27 20:02:39 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -3701,6 +3701,20 @@ ] }, { +'return_type' => 'void', +'name' => 'modperl_svptr_table_clear', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'tbl' + } +] + }, + { 'return_type' => 'PTR_TBL_t *', 'name' => 'modperl_svptr_table_clone', 'args' => [ @@ -3751,6 +3765,84 @@ ] }, { +'return_type' => 'void *', +'name' => 'modperl_svptr_table_fetch', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'tbl' + }, + { +'type' => 'void *', +'name' => 'sv' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_svptr_table_free', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'tbl' + } +] + }, + { +'return_type' => 'PTR_TBL_t *', +'name' => 'modperl_svptr_table_new', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_svptr_table_split', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'tbl' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_svptr_table_store', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'tbl' + }, + { +'type' => 'void *', +'name' => 'oldv' + }, + { +'type' => 'void *', +'name' => 'newv' + } +] + }, + { 'return_type' => 'int', 'name' => 'modperl_sys_dlclose', 'args' => [ @@ -4532,6 +4624,10 @@ { 'return_type' => 'SV *', 'name' => 'mpxs_Apache__Directive_as_string', +'attr' => [ + 'static', + '__inline__' +], 'args' => [ { 'type' => 'PerlInterpreter *',
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2002/08/27 19:24:48 Modified:xs/APR/Bucket APR__Bucket.h xs/maps apr_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: add the APR::Bucket::is_flush glue function Revision ChangesPath 1.5 +5 -0 modperl-2.0/xs/APR/Bucket/APR__Bucket.h Index: APR__Bucket.h === RCS file: /home/cvs/modperl-2.0/xs/APR/Bucket/APR__Bucket.h,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- APR__Bucket.h 30 May 2002 02:33:48 - 1.4 +++ APR__Bucket.h 28 Aug 2002 02:24:47 - 1.5 @@ -44,6 +44,11 @@ return APR_BUCKET_IS_EOS(bucket); } +static MP_INLINE int mpxs_APR__Bucket_is_flush(apr_bucket *bucket) +{ +return APR_BUCKET_IS_FLUSH(bucket); +} + static MP_INLINE void mpxs_APR__Bucket_insert_before(apr_bucket *a, apr_bucket *b) { 1.46 +1 -0 modperl-2.0/xs/maps/apr_functions.map Index: apr_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apr_functions.map,v retrieving revision 1.45 retrieving revision 1.46 diff -u -r1.45 -r1.46 --- apr_functions.map 23 Jun 2002 22:00:03 - 1.45 +++ apr_functions.map 28 Aug 2002 02:24:47 - 1.46 @@ -102,6 +102,7 @@ mpxs_APR__Brigade_empty#APR_BRIGADE_EMPTY MODULE=APR::Bucket + mpxs_APR__Bucket_is_flush #APR_BUCKET_IS_FLUSH mpxs_APR__Bucket_is_eos #APR_BUCKET_IS_EOS mpxs_APR__Bucket_insert_after #APR_BUCKET_INSERT_AFTER mpxs_APR__Bucket_insert_before #APR_BUCKET_INSERT_AFTER 1.83 +15 -27modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.82 retrieving revision 1.83 diff -u -r1.82 -r1.83 --- FunctionTable.pm 27 Aug 2002 04:28:48 - 1.82 +++ FunctionTable.pm 28 Aug 2002 02:24:47 - 1.83 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Mon Aug 26 19:47:54 2002 +# ! Wed Aug 28 10:12:34 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -4343,6 +4343,20 @@ ] }, { +'return_type' => 'int', +'name' => 'mpxs_APR__Bucket_is_flush', +'attr' => [ + 'static', + '__inline__' +], +'args' => [ + { +'type' => 'apr_bucket *', +'name' => 'bucket' + } +] + }, + { 'return_type' => 'apr_bucket *', 'name' => 'mpxs_APR__Bucket_new', 'attr' => [ @@ -5507,32 +5521,6 @@ { 'type' => 'SV *', 'name' => 'arg' - } -] - }, - { -'return_type' => 'apr_global_mutex_t *', -'name' => 'mpxs_apr_global_mutex_create', -'args' => [ - { -'type' => 'PerlInterpreter *', -'name' => 'my_perl' - }, - { -'type' => 'SV *', -'name' => 'classname' - }, - { -'type' => 'apr_pool_t *', -'name' => 'pool' - }, - { -'type' => 'const char *', -'name' => 'fname' - }, - { -'type' => 'apr_lockmech_e', -'name' => 'mech' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/08/26 21:28:48 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.82 +192 -1modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.81 retrieving revision 1.82 diff -u -r1.81 -r1.82 --- FunctionTable.pm 24 Aug 2002 17:14:40 - 1.81 +++ FunctionTable.pm 27 Aug 2002 04:28:48 - 1.82 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Sat Aug 24 09:39:05 2002 +# ! Mon Aug 26 19:47:54 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -606,6 +606,24 @@ }, { 'return_type' => 'const char *', +'name' => 'modperl_cmd_load_module', +'args' => [ + { +'type' => 'cmd_parms *', +'name' => 'parms' + }, + { +'type' => 'void *', +'name' => 'mconfig' + }, + { +'type' => 'const char *', +'name' => 'arg' + } +] + }, + { +'return_type' => 'const char *', 'name' => 'modperl_cmd_log_handlers', 'args' => [ { @@ -2295,6 +2313,48 @@ ] }, { +'return_type' => 'modperl_interp_t *', +'name' => 'modperl_interp_pool_get', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'p' + } +] + }, + { +'return_type' => 'modperl_interp_t *', +'name' => 'modperl_interp_pool_select', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + { +'type' => 'server_rec *', +'name' => 's' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_interp_pool_set', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + { +'type' => 'modperl_interp_t *', +'name' => 'interp' + }, + { +'type' => 'int', +'name' => 'cleanup' + } +] + }, + { 'return_type' => 'const char *', 'name' => 'modperl_interp_scope_desc', 'args' => [ @@ -2430,6 +2490,11 @@ ] }, { +'return_type' => 'int', +'name' => 'modperl_is_running', +'args' => [] + }, + { 'return_type' => 'modperl_list_t *', 'name' => 'modperl_list_append', 'args' => [ @@ -2742,6 +2807,52 @@ ] }, { +'return_type' => 'const char *', +'name' => 'modperl_module_add', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + { +'type' => 'server_rec *', +'name' => 's' + }, + { +'type' => 'const char *', +'name' => 'name' + } +] + }, + { +'return_type' => 'PTR_TBL_t *', +'name' => 'modperl_module_config_table_get', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'int', +'name' => 'create' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_module_config_table_set', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'table' + } +] + }, + { 'return_type' => 'SV *', 'name' => 'modperl_newSVsv_obj', 'attr' => [ @@ -3590,6 +3701,56 @@ ] }, { +'return_type' => 'PTR_TBL_t *', +'name' => 'modperl_svptr_table_clone', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PerlInterpreter *', +'name' => 'proto_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'source' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_svptr_table_delete', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *', +'name' => 'tbl' + }, + { +'type' => 'void *', +'name' => 'key' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_svptr_table_destroy', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'PTR_TBL_t *
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
stas2002/08/21 10:25:10 Modified:xs/Apache/Connection Apache__Connection.h xs/tables/current/ModPerl FunctionTable.pm Log: fix the incorrect return type for get_remote_host s/char */const char */ Revision ChangesPath 1.5 +1 -1 modperl-2.0/xs/Apache/Connection/Apache__Connection.h Index: Apache__Connection.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/Connection/Apache__Connection.h,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Apache__Connection.h 15 Aug 2002 08:42:55 - 1.4 +++ Apache__Connection.h 21 Aug 2002 17:25:10 - 1.5 @@ -13,7 +13,7 @@ } static MP_INLINE -char *mpxs_Apache__Connection_get_remote_host(pTHX_ conn_rec *c, +const char *mpxs_Apache__Connection_get_remote_host(pTHX_ conn_rec *c, int type, apr_table_t *dir_config) { 1.77 +1 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.76 retrieving revision 1.77 diff -u -r1.76 -r1.77 --- FunctionTable.pm 15 Aug 2002 08:42:55 - 1.76 +++ FunctionTable.pm 21 Aug 2002 17:25:10 - 1.77 @@ -4305,7 +4305,7 @@ ] }, { -'return_type' => 'char *', +'return_type' => 'const char *', 'name' => 'mpxs_Apache__Connection_get_remote_host', 'args' => [ {
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/06/23 14:28:15 Modified:xs/maps apr_functions.map apr_types.map xs/tables/current/ModPerl FunctionTable.pm Log: add APR::ThreadMutex module Revision ChangesPath 1.44 +4 -3 modperl-2.0/xs/maps/apr_functions.map Index: apr_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apr_functions.map,v retrieving revision 1.43 retrieving revision 1.44 diff -u -r1.43 -r1.44 --- apr_functions.map 24 May 2002 17:47:27 - 1.43 +++ apr_functions.map 23 Jun 2002 21:28:14 - 1.44 @@ -344,9 +344,10 @@ -apr_proc_other_child_check -apr_proc_wait_all_procs -!MODULE=APR::ThreadMutex - apr_thread_mutex_create - apr_thread_mutex_destroy +MODULE=APR::ThreadMutex PREFIX=apr_thread_mutex_ + apr_thread_mutex_t *:apr_thread_mutex_create | mpxs_ | \ + SV *:classname, pool, flags=APR_THREAD_MUTEX_DEFAULT | new + void:apr_thread_mutex_destroy | | | apr_thread_mutex_DESTROY apr_thread_mutex_lock apr_thread_mutex_trylock apr_thread_mutex_unlock 1.19 +1 -1 modperl-2.0/xs/maps/apr_types.map Index: apr_types.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apr_types.map,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- apr_types.map 23 May 2002 19:49:49 - 1.18 +++ apr_types.map 23 Jun 2002 21:28:14 - 1.19 @@ -100,7 +100,7 @@ struct apr_thread_t | UNDEFINED apr_thread_start_t | UNDEFINED struct apr_threadattr_t | UNDEFINED -struct apr_thread_mutex_t| UNDEFINED +struct apr_thread_mutex_t| APR::ThreadMutex struct apr_thread_once_t | UNDEFINED struct apr_thread_cond_t | UNDEFINED struct apr_thread_rwlock_t | UNDEFINED 1.75 +27 -2 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.74 retrieving revision 1.75 diff -u -r1.74 -r1.75 --- FunctionTable.pm 21 Jun 2002 03:04:36 - 1.74 +++ FunctionTable.pm 23 Jun 2002 21:28:15 - 1.75 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Thu Jun 20 19:51:30 2002 +# ! Sun Jun 23 13:55:55 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -3836,7 +3836,7 @@ 'name' => 'modperl_trace', 'args' => [ { -'type' => 'char *', +'type' => 'const char *', 'name' => 'func' }, { @@ -5473,6 +5473,31 @@ { 'type' => 'const char *', 'name' => 'val' + } +] + }, + { +'return_type' => '__inline__', +'name' => 'mpxs_apr_thread_mutex_create', +'attr' => [ + 'static' +], +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'SV *', +'name' => 'classname' + }, + { +'type' => 'apr_pool_t *', +'name' => 'pool' + }, + { +'type' => 'unsigned int', +'name' => 'flags' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/06/20 20:04:36 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.74 +4 -21 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.73 retrieving revision 1.74 diff -u -r1.73 -r1.74 --- FunctionTable.pm 21 Jun 2002 00:07:24 - 1.73 +++ FunctionTable.pm 21 Jun 2002 03:04:36 - 1.74 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Thu Jun 20 16:54:53 2002 +# ! Thu Jun 20 19:51:30 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -2275,10 +2275,6 @@ 'name' => 'modperl_interp_new', 'args' => [ { -'type' => 'apr_pool_t *', -'name' => 'p' - }, - { 'type' => 'modperl_interp_pool_t *', 'name' => 'mip' }, @@ -2470,12 +2466,7 @@ { 'return_type' => 'modperl_list_t *', 'name' => 'modperl_list_new', -'args' => [ - { -'type' => 'apr_pool_t *', -'name' => 'p' - } -] +'args' => [] }, { 'return_type' => 'modperl_list_t *', @@ -3975,26 +3966,18 @@ 'name' => 'modperl_xs_dl_handles_close', 'args' => [ { -'type' => 'apr_pool_t *', -'name' => 'p' - }, - { -'type' => 'apr_array_header_t *', +'type' => 'void **', 'name' => 'handles' } ] }, { -'return_type' => 'apr_array_header_t *', +'return_type' => 'void **', 'name' => 'modperl_xs_dl_handles_get', 'args' => [ { 'type' => 'PerlInterpreter *', 'name' => 'my_perl' - }, - { -'type' => 'apr_pool_t *', -'name' => 'p' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/06/20 17:07:25 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.73 +11 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.72 retrieving revision 1.73 diff -u -r1.72 -r1.73 --- FunctionTable.pm 16 Jun 2002 01:09:18 - 1.72 +++ FunctionTable.pm 21 Jun 2002 00:07:24 - 1.73 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Sat Jun 15 17:57:19 2002 +# ! Thu Jun 20 16:54:53 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -3581,6 +3581,16 @@ { 'type' => 'SV *', 'name' => 'sv' + } +] + }, + { +'return_type' => 'int', +'name' => 'modperl_sys_dlclose', +'args' => [ + { +'type' => 'void *', +'name' => 'handle' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/06/15 18:09:18 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.72 +54 -19modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.71 retrieving revision 1.72 diff -u -r1.71 -r1.72 --- FunctionTable.pm 3 Jun 2002 23:46:44 - 1.71 +++ FunctionTable.pm 16 Jun 2002 01:09:18 - 1.72 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Sat May 25 11:12:06 2002 +# ! Sat Jun 15 17:57:19 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -1355,6 +1355,11 @@ ] }, { +'return_type' => 'void', +'name' => 'modperl_env_unload', +'args' => [] + }, + { 'return_type' => 'int', 'name' => 'modperl_errsv', 'args' => [ @@ -2082,6 +2087,24 @@ ] }, { +'return_type' => 'int', +'name' => 'modperl_hook_pre_config', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + { +'type' => 'apr_pool_t *', +'name' => 'plog' + }, + { +'type' => 'apr_pool_t *', +'name' => 'ptemp' + } +] + }, + { 'return_type' => 'void', 'name' => 'modperl_init', 'args' => [ @@ -3175,6 +3198,36 @@ ] }, { +'return_type' => 'void', +'name' => 'modperl_perl_pp_set', +'args' => [ + { +'type' => 'modperl_perl_opcode_e', +'name' => 'idx' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_perl_pp_set_all', +'args' => [] + }, + { +'return_type' => 'void', +'name' => 'modperl_perl_pp_unset', +'args' => [ + { +'type' => 'modperl_perl_opcode_e', +'name' => 'idx' + } +] + }, + { +'return_type' => 'void', +'name' => 'modperl_perl_pp_unset_all', +'args' => [] + }, + { 'return_type' => 'SV *', 'name' => 'modperl_perl_sv_setref_uv', 'attr' => [ @@ -3228,24 +3281,6 @@ { 'type' => 'request_rec *', 'name' => 'r' - } -] - }, - { -'return_type' => 'int', -'name' => 'modperl_hook_pre_config', -'args' => [ - { -'type' => 'apr_pool_t *', -'name' => 'p' - }, - { -'type' => 'apr_pool_t *', -'name' => 'plog' - }, - { -'type' => 'apr_pool_t *', -'name' => 'ptemp' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 2002/06/03 16:46:44 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: need to update pre_config hook namechange for win32 .def Revision ChangesPath 1.71 +2 -2 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.70 retrieving revision 1.71 diff -u -r1.70 -r1.71 --- FunctionTable.pm 30 May 2002 02:33:48 - 1.70 +++ FunctionTable.pm 3 Jun 2002 23:46:44 - 1.71 @@ -3232,8 +3232,8 @@ ] }, { -'return_type' => 'void', -'name' => 'modperl_pre_config_handler', +'return_type' => 'int', +'name' => 'modperl_hook_pre_config', 'args' => [ { 'type' => 'apr_pool_t *',
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/29 19:33:49 Modified:src/modules/perl modperl_filter.c modperl_filter.h xs/APR/Bucket APR__Bucket.h xs/Apache/RequestIO Apache__RequestIO.h xs/tables/current/ModPerl FunctionTable.pm Log: use apr_size_t rather than apr_ssize_t for apr_bucket_read (gets rid of some warnings on darwin) Revision ChangesPath 1.35 +10 -10modperl-2.0/src/modules/perl/modperl_filter.c Index: modperl_filter.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.c,v retrieving revision 1.34 retrieving revision 1.35 diff -u -r1.34 -r1.35 --- modperl_filter.c 6 Apr 2002 01:19:15 - 1.34 +++ modperl_filter.c 30 May 2002 02:33:48 - 1.35 @@ -3,7 +3,7 @@ /* simple buffer api */ MP_INLINE apr_status_t modperl_wbucket_pass(modperl_wbucket_t *wb, -const char *buf, apr_ssize_t len) +const char *buf, apr_size_t len) { apr_bucket_alloc_t *ba = (*wb->filters)->c->bucket_alloc; apr_bucket_brigade *bb; @@ -52,9 +52,9 @@ MP_INLINE apr_status_t modperl_wbucket_write(modperl_wbucket_t *wb, const char *buf, - apr_ssize_t *wlen) + apr_size_t *wlen) { -apr_ssize_t len = *wlen; +apr_size_t len = *wlen; *wlen = 0; if ((len + wb->outcnt) > sizeof(wb->outbuf)) { @@ -226,13 +226,13 @@ return 0; } -MP_INLINE apr_ssize_t modperl_output_filter_read(pTHX_ - modperl_filter_t *filter, - SV *buffer, - apr_ssize_t wanted) +MP_INLINE apr_size_t modperl_output_filter_read(pTHX_ +modperl_filter_t *filter, +SV *buffer, +apr_size_t wanted) { int num_buckets = 0; -apr_ssize_t len = 0; +apr_size_t len = 0; (void)SvUPGRADE(buffer, SVt_PV); SvPOK_only(buffer); @@ -268,7 +268,7 @@ while (1) { const char *buf; -apr_ssize_t buf_len; +apr_size_t buf_len; if (!get_bucket(filter)) { break; @@ -361,7 +361,7 @@ MP_INLINE apr_status_t modperl_output_filter_write(modperl_filter_t *filter, const char *buf, - apr_ssize_t *len) + apr_size_t *len) { return modperl_wbucket_write(&filter->wbucket, buf, len); } 1.14 +7 -7 modperl-2.0/src/modules/perl/modperl_filter.h Index: modperl_filter.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.h,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- modperl_filter.h 6 Apr 2002 01:19:15 - 1.13 +++ modperl_filter.h 30 May 2002 02:33:48 - 1.14 @@ -12,13 +12,13 @@ /* simple buffer api */ MP_INLINE apr_status_t modperl_wbucket_pass(modperl_wbucket_t *b, -const char *buf, apr_ssize_t len); +const char *buf, apr_size_t len); MP_INLINE apr_status_t modperl_wbucket_flush(modperl_wbucket_t *b); MP_INLINE apr_status_t modperl_wbucket_write(modperl_wbucket_t *b, const char *buf, - apr_ssize_t *wlen); + apr_size_t *wlen); /* generic filter routines */ @@ -43,14 +43,14 @@ MP_INLINE apr_status_t modperl_output_filter_flush(modperl_filter_t *filter); -MP_INLINE apr_ssize_t modperl_output_filter_read(pTHX_ - modperl_filter_t *filter, - SV *buffer, - apr_ssize_t wanted); +MP_INLINE apr_size_t modperl_output_filter_read(pTHX_ +modperl_filter_t *filter, +SV *buffer, +apr_size_t wanted); MP_INLINE apr_status_t modperl_output_filter_write(modperl_filter_t *filter, const char *buf, - apr_ssize_t *len); +
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/25 11:36:37 Modified:xs/tables/current/Apache FunctionTable.pm StructureTable.pm xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.38 +184 -4modperl-2.0/xs/tables/current/Apache/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/FunctionTable.pm,v retrieving revision 1.37 retrieving revision 1.38 diff -u -r1.37 -r1.38 --- FunctionTable.pm 18 May 2002 23:56:54 - 1.37 +++ FunctionTable.pm 25 May 2002 18:36:36 - 1.38 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Sat May 18 16:24:44 2002 +# ! Sat May 25 11:12:00 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -3032,7 +3032,7 @@ ] }, { -'return_type' => 'apr_status_t', +'return_type' => 'int', 'name' => 'ap_mpm_pod_check', 'args' => [ { @@ -3062,6 +3062,10 @@ { 'type' => 'int', 'name' => 'num' + }, + { +'type' => 'int', +'name' => 'graceful' } ] }, @@ -3086,6 +3090,20 @@ { 'type' => 'ap_pod_t *', 'name' => 'pod' + }, + { +'type' => 'int', +'name' => 'graceful' + } +] + }, + { +'return_type' => 'void', +'name' => 'ap_mpm_rewrite_args', +'args' => [ + { +'type' => 'process_rec *', +'name' => 'arg0' } ] }, @@ -3602,6 +3620,136 @@ ] }, { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_info_create', +'args' => [ + { +'type' => 'fd_queue_info_t **', +'name' => 'queue_info' + }, + { +'type' => 'apr_pool_t *', +'name' => 'pool' + }, + { +'type' => 'int', +'name' => 'max_idlers' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_info_set_idle', +'args' => [ + { +'type' => 'fd_queue_info_t *', +'name' => 'queue_info' + }, + { +'type' => 'apr_pool_t *', +'name' => 'pool_to_recycle' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_info_term', +'args' => [ + { +'type' => 'fd_queue_info_t *', +'name' => 'queue_info' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_info_wait_for_idler', +'args' => [ + { +'type' => 'fd_queue_info_t *', +'name' => 'queue_info' + }, + { +'type' => 'apr_pool_t **', +'name' => 'recycled_pool' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_init', +'args' => [ + { +'type' => 'fd_queue_t *', +'name' => 'queue' + }, + { +'type' => 'int', +'name' => 'queue_capacity' + }, + { +'type' => 'apr_pool_t *', +'name' => 'a' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_interrupt_all', +'args' => [ + { +'type' => 'fd_queue_t *', +'name' => 'queue' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_pop', +'args' => [ + { +'type' => 'fd_queue_t *', +'name' => 'queue' + }, + { +'type' => 'apr_socket_t **', +'name' => 'sd' + }, + { +'type' => 'apr_pool_t **', +'name' => 'p' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_push', +'args' => [ + { +'type' => 'fd_queue_t *', +'name' => 'queue' + }, + { +'type' => 'apr_socket_t *', +'name' => 'sd' + }, + { +'type' => 'apr_pool_t *', +'name' => 'p' + } +] + }, + { +'return_type' => 'apr_status_t', +'name' => 'ap_queue_term', +'args' => [ + { +'type' => 'fd_queue_t *', +'name' => 'queue' + } +] + }, + { 'return_type' => 'apr_time_t', 'name' => 'ap_rationalize_mtime', 'args' => [ @@ -3638,6 +3786,24 @@ ] }, { +'return_type' => 'apr_status_t', +'name' => 'ap_read_pid', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + {
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/23 22:13:08 Modified:xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.68 +26 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.67 retrieving revision 1.68 diff -u -r1.67 -r1.68 --- FunctionTable.pm 22 May 2002 16:30:40 - 1.67 +++ FunctionTable.pm 24 May 2002 05:13:07 - 1.68 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Wed May 22 09:10:46 2002 +# ! Thu May 23 22:06:43 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -3171,6 +3171,31 @@ { 'type' => 'const char *', 'name' => 'name' + } +] + }, + { +'return_type' => 'SV *', +'name' => 'modperl_perl_sv_setref_uv', +'attr' => [ + '__inline__' +], +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'SV *', +'name' => 'rv' + }, + { +'type' => 'const char *', +'name' => 'classname' + }, + { +'type' => 'UV', +'name' => 'uv' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/22 09:30:40 Modified:t/apr.cvsignore xs/maps apr_functions.map apr_types.map xs/tables/current/ModPerl FunctionTable.pm Log: add APR::OS::thread_current function Revision ChangesPath 1.5 +1 -0 modperl-2.0/t/apr/.cvsignore Index: .cvsignore === RCS file: /home/cvs/modperl-2.0/t/apr/.cvsignore,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- .cvsignore6 Mar 2002 05:24:57 - 1.4 +++ .cvsignore22 May 2002 16:30:40 - 1.5 @@ -9,3 +9,4 @@ table.t util.t uuid.t +os.t 1.41 +25 -25modperl-2.0/xs/maps/apr_functions.map Index: apr_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apr_functions.map,v retrieving revision 1.40 retrieving revision 1.41 diff -u -r1.40 -r1.41 --- apr_functions.map 19 May 2002 23:59:52 - 1.40 +++ apr_functions.map 22 May 2002 16:30:40 - 1.41 @@ -591,28 +591,28 @@ apr_xlate_get_sb apr_xlate_open --MODULE=APR::OS - apr_os_dir_get - apr_os_exp_time_get - apr_os_file_get - apr_os_imp_time_get - apr_os_sock_get - apr_os_thread_get - apr_os_threadkey_get - apr_os_sock_make - apr_os_dir_put - apr_os_exp_time_put - apr_os_file_put - apr_os_imp_time_put - apr_os_sock_put - apr_os_thread_put - apr_os_threadkey_put - apr_os_dso_handle_get - apr_os_dso_handle_put - apr_os_thread_current - apr_os_thread_equal - apr_os_global_mutex_get - apr_os_proc_mutex_get - apr_os_proc_mutex_put - apr_os_shm_get - apr_os_shm_put +MODULE=APR::OS +-apr_os_dir_get +-apr_os_exp_time_get +-apr_os_file_get +-apr_os_imp_time_get +-apr_os_sock_get +-apr_os_thread_get +-apr_os_threadkey_get +-apr_os_sock_make +-apr_os_dir_put +-apr_os_exp_time_put +-apr_os_file_put +-apr_os_imp_time_put +-apr_os_sock_put +-apr_os_thread_put +-apr_os_threadkey_put +-apr_os_dso_handle_get +-apr_os_dso_handle_put + apr_os_thread_current | | mpxs_ +-apr_os_thread_equal +-apr_os_global_mutex_get +-apr_os_proc_mutex_get +-apr_os_proc_mutex_put +-apr_os_shm_get +-apr_os_shm_put 1.17 +1 -1 modperl-2.0/xs/maps/apr_types.map Index: apr_types.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apr_types.map,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- apr_types.map 19 May 2002 01:05:30 - 1.16 +++ apr_types.map 22 May 2002 16:30:40 - 1.17 @@ -96,7 +96,7 @@ #thread stuff struct apr_threadkey_t | UNDEFINED struct apr_os_threadkey_t| UNDEFINED -struct apr_os_thread_t | UNDEFINED +struct apr_os_thread_t | PTR struct apr_thread_t | UNDEFINED apr_thread_start_t | UNDEFINED struct apr_threadattr_t | UNDEFINED 1.67 +15 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.66 retrieving revision 1.67 diff -u -r1.66 -r1.67 --- FunctionTable.pm 21 May 2002 02:50:16 - 1.66 +++ FunctionTable.pm 22 May 2002 16:30:40 - 1.67 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Mon May 20 19:15:12 2002 +# ! Wed May 22 09:10:46 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -5195,6 +5195,20 @@ { 'type' => 'const char *', 'name' => 'mask_or_numbits' + } +] + }, + { +'return_type' => 'apr_os_thread_t', +'name' => 'mpxs_apr_os_thread_current', +'attr' => [ + 'static', + '__inline__' +], +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/20 19:50:16 Modified:t/modperl .cvsignore xs/Apache/RequestRec Apache__RequestRec.h xs/maps apache_structures.map modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: support 1.x subprocess_env functionality Revision ChangesPath 1.8 +1 -0 modperl-2.0/t/modperl/.cvsignore Index: .cvsignore === RCS file: /home/cvs/modperl-2.0/t/modperl/.cvsignore,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- .cvsignore15 Nov 2001 03:02:43 - 1.7 +++ .cvsignore21 May 2002 02:50:15 - 1.8 @@ -5,3 +5,4 @@ print.t pnotes.t dir_config.t +subenv.t 1.4 +12 -0 modperl-2.0/xs/Apache/RequestRec/Apache__RequestRec.h Index: Apache__RequestRec.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestRec/Apache__RequestRec.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- Apache__RequestRec.h 21 May 2002 00:22:24 - 1.3 +++ Apache__RequestRec.h 21 May 2002 02:50:16 - 1.4 @@ -39,3 +39,15 @@ return retval; } + +static MP_INLINE +SV *mpxs_Apache__RequestRec_subprocess_env(pTHX_ request_rec *r, + char *key, SV *val) +{ +if (GIMME_V == G_VOID) { +modperl_env_request_populate(aTHX_ r); +} + +return modperl_table_get_set(aTHX_ r->subprocess_env, + key, val, TRUE); +} 1.17 +1 -1 modperl-2.0/xs/maps/apache_structures.map Index: apache_structures.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apache_structures.map,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- apache_structures.map 21 May 2002 00:22:24 - 1.16 +++ apache_structures.map 21 May 2002 02:50:16 - 1.17 @@ -38,7 +38,7 @@ headers_in headers_out err_headers_out - subprocess_env +~ subprocess_env notes ~ content_type handler 1.39 +3 -2 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.38 retrieving revision 1.39 diff -u -r1.38 -r1.39 --- modperl_functions.map 21 May 2002 00:22:24 - 1.38 +++ modperl_functions.map 21 May 2002 02:50:16 - 1.39 @@ -9,8 +9,9 @@ mpxs_ModPerl__Global_special_list_clear MODULE=Apache::RequestRec PACKAGE=Apache::RequestRec - mpxs_Apache__RequestRec_content_type | | r, type=Nullsv - mpxs_Apache__RequestRec_proxyreq | | r, val=Nullsv + mpxs_Apache__RequestRec_content_type | | r, type=Nullsv + mpxs_Apache__RequestRec_proxyreq | | r, val=Nullsv + mpxs_Apache__RequestRec_subprocess_env | | r, key=NULL, val=Nullsv MODULE=Apache::RequestUtil PACKAGE=guess mpxs_Apache__RequestRec_push_handlers 1.66 +23 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.65 retrieving revision 1.66 diff -u -r1.65 -r1.66 --- FunctionTable.pm 21 May 2002 00:22:24 - 1.65 +++ FunctionTable.pm 21 May 2002 02:50:16 - 1.66 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Mon May 20 16:47:17 2002 +# ! Mon May 20 19:15:12 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -4675,6 +4675,28 @@ { 'type' => 'apr_time_t', 'name' => 'mtime' + } +] + }, + { +'return_type' => 'SV *', +'name' => 'mpxs_Apache__RequestRec_subprocess_env', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'request_rec *', +'name' => 'r' + }, + { +'type' => 'char *', +'name' => 'key' + }, + { +'type' => 'SV *', +'name' => 'val' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/20 17:22:24 Modified:src/modules/perl modperl_apache_includes.h xs/Apache/RequestRec Apache__RequestRec.h xs/maps apache_structures.map modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: add support for $r->proxyreq to detect proxy requests Revision ChangesPath 1.14 +1 -0 modperl-2.0/src/modules/perl/modperl_apache_includes.h Index: modperl_apache_includes.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_apache_includes.h,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- modperl_apache_includes.h 13 May 2002 03:17:54 - 1.13 +++ modperl_apache_includes.h 21 May 2002 00:22:24 - 1.14 @@ -16,6 +16,7 @@ #include "http_request.h" #include "http_connection.h" #include "http_core.h" +#include "http_vhost.h" #include "ap_mpm.h" #include "apr_lib.h" 1.3 +27 -0 modperl-2.0/xs/Apache/RequestRec/Apache__RequestRec.h Index: Apache__RequestRec.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestRec/Apache__RequestRec.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- Apache__RequestRec.h 21 May 2002 00:07:00 - 1.2 +++ Apache__RequestRec.h 21 May 2002 00:22:24 - 1.3 @@ -12,3 +12,30 @@ return retval; } + +static MP_INLINE +int mpxs_Apache__RequestRec_proxyreq(pTHX_ request_rec *r, SV *val) +{ +int retval = r->proxyreq; + +if (!val && !r->proxyreq && +r->parsed_uri.scheme && + !(r->parsed_uri.hostname && + strEQ(r->parsed_uri.scheme, ap_http_method(r)) && + ap_matches_request_vhost(r, r->parsed_uri.hostname, + r->parsed_uri.port_str ? + r->parsed_uri.port : + ap_default_port(r +{ +retval = r->proxyreq = 1; +r->uri = r->unparsed_uri; +/* else mod_proxy will segfault */ +r->filename = apr_pstrcat(r->pool, "modperl-proxy:", r->uri, NULL); +} + +if (val) { +r->proxyreq = SvIV(val); +} + +return retval; +} 1.16 +1 -1 modperl-2.0/xs/maps/apache_structures.map Index: apache_structures.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apache_structures.map,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- apache_structures.map 19 May 2002 20:11:55 - 1.15 +++ apache_structures.map 21 May 2002 00:22:24 - 1.16 @@ -11,7 +11,7 @@ main the_request assbackwards - proxyreq +~ proxyreq header_only protocol proto_num 1.38 +1 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.37 retrieving revision 1.38 diff -u -r1.37 -r1.38 --- modperl_functions.map 19 May 2002 20:11:55 - 1.37 +++ modperl_functions.map 21 May 2002 00:22:24 - 1.38 @@ -10,6 +10,7 @@ MODULE=Apache::RequestRec PACKAGE=Apache::RequestRec mpxs_Apache__RequestRec_content_type | | r, type=Nullsv + mpxs_Apache__RequestRec_proxyreq | | r, val=Nullsv MODULE=Apache::RequestUtil PACKAGE=guess mpxs_Apache__RequestRec_push_handlers 1.65 +19 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.64 retrieving revision 1.65 diff -u -r1.64 -r1.65 --- FunctionTable.pm 19 May 2002 20:11:55 - 1.64 +++ FunctionTable.pm 21 May 2002 00:22:24 - 1.65 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Sun May 19 12:59:55 2002 +# ! Mon May 20 16:47:17 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -4516,6 +4516,24 @@ { 'type' => 'SV **', 'name' => 'sp' + } +] + }, + { +'return_type' => 'int', +'name' => 'mpxs_Apache__RequestRec_proxyreq', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'request_rec *', +'name' => 'r' + }, +
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/19 13:11:56 Modified:xs/maps apache_functions.map apache_structures.map modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Log: wrap $r->content_type("foo/bar") so ap_set_content_type is called underneath Revision ChangesPath 1.51 +1 -1 modperl-2.0/xs/maps/apache_functions.map Index: apache_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apache_functions.map,v retrieving revision 1.50 retrieving revision 1.51 diff -u -r1.50 -r1.51 --- apache_functions.map 19 May 2002 01:05:30 - 1.50 +++ apache_functions.map 19 May 2002 20:11:55 - 1.51 @@ -49,7 +49,7 @@ >ap_rgetline_core ?ap_get_request_note ?ap_register_request_note - ap_set_content_type +~ap_set_content_type #MODULE=Apache::RequestConfig ap_document_root 1.15 +1 -1 modperl-2.0/xs/maps/apache_structures.map Index: apache_structures.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apache_structures.map,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- apache_structures.map 19 May 2002 01:05:30 - 1.14 +++ apache_structures.map 19 May 2002 20:11:55 - 1.15 @@ -40,7 +40,7 @@ err_headers_out subprocess_env notes - content_type +~ content_type handler content_encoding content_languages 1.37 +3 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.36 retrieving revision 1.37 diff -u -r1.36 -r1.37 --- modperl_functions.map 10 May 2002 17:48:27 - 1.36 +++ modperl_functions.map 19 May 2002 20:11:55 - 1.37 @@ -8,6 +8,9 @@ mpxs_ModPerl__Global_special_list_call mpxs_ModPerl__Global_special_list_clear +MODULE=Apache::RequestRec PACKAGE=Apache::RequestRec + mpxs_Apache__RequestRec_content_type | | r, type=Nullsv + MODULE=Apache::RequestUtil PACKAGE=guess mpxs_Apache__RequestRec_push_handlers mpxs_Apache__RequestRec_set_handlers 1.64 +19 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.63 retrieving revision 1.64 diff -u -r1.63 -r1.64 --- FunctionTable.pm 18 May 2002 23:56:54 - 1.63 +++ FunctionTable.pm 19 May 2002 20:11:55 - 1.64 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Sat May 18 16:46:32 2002 +# ! Sun May 19 12:59:55 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -4366,6 +4366,24 @@ { 'type' => 'request_rec *', 'name' => 'r' + } +] + }, + { +'return_type' => 'const char *', +'name' => 'mpxs_Apache__RequestRec_content_type', +'args' => [ + { +'type' => 'PerlInterpreter *', +'name' => 'my_perl' + }, + { +'type' => 'request_rec *', +'name' => 'r' + }, + { +'type' => 'SV *', +'name' => 'type' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/18 16:56:55 Modified:xs/tables/current/Apache ConstantsTable.pm FunctionTable.pm StructureTable.pm xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.26 +3 -2 modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm Index: ConstantsTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm,v retrieving revision 1.25 retrieving revision 1.26 diff -u -r1.25 -r1.26 --- ConstantsTable.pm 18 May 2002 02:29:44 - 1.25 +++ ConstantsTable.pm 18 May 2002 23:56:54 - 1.26 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Fri Apr 5 13:00:31 2002 +# ! Sat May 18 16:24:40 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -84,6 +84,7 @@ 'APLOG_DEBUG', 'APLOG_LEVELMASK', 'APLOG_NOERRNO', + 'APLOG_TOCLIENT', 'APLOG_STARTUP' ], 'input_mode' => [ @@ -314,7 +315,6 @@ 'APR_APPEND', 'APR_TRUNCATE', 'APR_BINARY', - 'APR_EXCL', 'APR_BUFFERED', 'APR_DELONCLOSE' ], @@ -372,6 +372,7 @@ 'APR_EPIPE', 'APR_EXDEV', 'APR_ENOTEMPTY', + 'APR_EXCL', 'APR_END' ], 'common' => [ 1.37 +245 -241 modperl-2.0/xs/tables/current/Apache/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/FunctionTable.pm,v retrieving revision 1.36 retrieving revision 1.37 diff -u -r1.36 -r1.37 --- FunctionTable.pm 6 Apr 2002 00:39:59 - 1.36 +++ FunctionTable.pm 18 May 2002 23:56:54 - 1.37 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Fri Apr 5 13:00:37 2002 +# ! Sat May 18 16:24:44 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -1226,6 +1226,16 @@ ] }, { +'return_type' => 'void', +'name' => 'ap_get_mime_headers', +'args' => [ + { +'type' => 'request_rec *', +'name' => 'r' + } +] + }, + { 'return_type' => 'ap_filter_rec_t *', 'name' => 'ap_get_output_filter_handle', 'args' => [ @@ -3652,6 +3662,20 @@ ] }, { +'return_type' => 'apr_status_t', +'name' => 'ap_recent_rfc822_date', +'args' => [ + { +'type' => 'char *', +'name' => 'date_str' + }, + { +'type' => 'apr_time_t', +'name' => 't' + } +] + }, + { 'return_type' => 'void', 'name' => 'ap_reclaim_child_processes', 'args' => [ @@ -3823,6 +3847,20 @@ ] }, { +'return_type' => 'apr_status_t', +'name' => 'ap_replace_stderr_log', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + { +'type' => 'const char *', +'name' => 'file' + } +] + }, + { 'return_type' => 'const apr_array_header_t *', 'name' => 'ap_requires', 'args' => [ @@ -4891,6 +4929,16 @@ }, { 'return_type' => 'void', +'name' => 'ap_setup_make_content_type', +'args' => [ + { +'type' => 'apr_pool_t *', +'name' => 'pool' + } +] + }, + { +'return_type' => 'void', 'name' => 'ap_setup_prelinked_modules', 'args' => [ { @@ -5447,11 +5495,11 @@ 'name' => 'argc' }, { -'type' => 'char ***', +'type' => 'char const * const * *', 'name' => 'argv' }, { -'type' => 'char ***', +'type' => 'char const * const * *', 'name' => 'env' } ] @@ -5563,6 +5611,82 @@ ] }, { +'return_type' => 'void', +'name' => 'apr_atomic_add', +'args' => [ + { +'type' => 'volatile apr_uint32_t *', +'name' => 'mem' + }, + { +'type' => 'apr_uint32_t', +'name' => 'val' + } +] + }, + { +'return_type' => 'apr_uint32_t', +'name' => 'apr_atomic_cas', +'args' => [ + { +'type' => 'volatile apr_uint32_t *', +'name' => 'mem' + }, + { +'type' => 'long', +'name' => 'with' + }, + { +'type' => 'long', +'name' => 'cmp' + } +
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/05/12 16:01:33 Modified:lib/ModPerl Code.pm src/modules/perl modperl_cmd.c modperl_config.c modperl_log.c modperl_log.h xs/tables/current/ModPerl FunctionTable.pm Log: get MP_TRACE working on win32 Revision ChangesPath 1.79 +4 -6 modperl-2.0/lib/ModPerl/Code.pm Index: Code.pm === RCS file: /home/cvs/modperl-2.0/lib/ModPerl/Code.pm,v retrieving revision 1.78 retrieving revision 1.79 diff -u -r1.78 -r1.79 --- Code.pm 23 Apr 2002 16:27:00 - 1.78 +++ Code.pm 12 May 2002 23:01:32 - 1.79 @@ -376,7 +376,7 @@ EOF push @dumper, - qq{fprintf(stderr, " $name %s\\n", \\ + qq{modperl_trace(NULL, " $name %s\\n", \\ ($flags(p) & $x) ? "On " : "Off");}; $i += $i || 1; @@ -389,7 +389,7 @@ shift @dumper; #NONE print $h_fh join ' \\'."\n", "#define ${class}_dump_flags(p, str)", - qq{fprintf(stderr, "$class flags dump (%s):\\n", str);}, + qq{modperl_trace(NULL, "$class flags dump (%s):\\n", str);}, @dumper; } @@ -428,8 +428,6 @@ my $tl = "MP_debug_level"; print $h_fhargv->elts; -fprintf(stderr, "modperl_config_srv_argv_init =>\n"); +modperl_trace(NULL, "modperl_config_srv_argv_init =>\n"); for (i=0; iargv->nelts; i++) { -fprintf(stderr, " %d = %s\n", i, argv[i]); +modperl_trace(NULL, " %d = %s\n", i, argv[i]); } } #endif 1.6 +37 -14modperl-2.0/src/modules/perl/modperl_log.c Index: modperl_log.c === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_log.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- modperl_log.c 21 Oct 2001 22:11:34 - 1.5 +++ modperl_log.c 12 May 2002 23:01:32 - 1.6 @@ -1,49 +1,72 @@ -#include "mod_perl.h" +#include "modperl_apache_includes.h" +#include "apr_lib.h" +#include "modperl_trace.h" +#include "modperl_log.h" #undef getenv /* from XSUB.h */ -U32 MP_debug_level = 0; +static apr_file_t *logfile = NULL; + +#ifdef WIN32 +static unsigned long debug_level = 0; +#else +unsigned long MP_debug_level = 0; +#define debug_level MP_debug_level +#endif + +unsigned long modperl_debug_level(void) +{ +return debug_level; +} void modperl_trace(char *func, const char *fmt, ...) { -#ifndef WIN32 /* XXX */ +char vstr[8192]; +apr_size_t vstr_len = 0; va_list args; +if (!logfile) { +return; +} + if (func) { -fprintf(stderr, "%s: ", func); +apr_file_printf(logfile, "%s: ", func); } va_start(args, fmt); -vfprintf(stderr, fmt, args); +vstr_len = apr_vsnprintf(vstr, sizeof(vstr), fmt, args); va_end(args); -#endif + +apr_file_write(logfile, vstr, &vstr_len); } -void modperl_trace_level_set(const char *level) +void modperl_trace_level_set(server_rec *s, const char *level) { if (!level) { if (!(level = getenv("MOD_PERL_TRACE"))) { return; } } -MP_debug_level = 0x0; +debug_level = 0x0; -if (strEQ(level, "all")) { -MP_debug_level = 0x; +if (strcasecmp(level, "all") == 0) { +debug_level = 0x; } -else if (isALPHA(level[0])) { +else if (apr_isalpha(level[0])) { static char debopts[] = MP_TRACE_OPTS; char *d; for (; *level && (d = strchr(debopts, *level)); level++) { -MP_debug_level |= 1 << (d - debopts); +debug_level |= 1 << (d - debopts); } } else { -MP_debug_level = atoi(level); +debug_level = atoi(level); } -MP_debug_level |= 0x8000; +debug_level |= 0x8000; + +logfile = s->error_log; /* XXX */ MP_TRACE_a_do(MP_TRACE_dump_flags()); } 1.8 +11 -3 modperl-2.0/src/modules/perl/modperl_log.h Index: modperl_lo
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/04/05 16:40:00 Modified:xs/tables/current/Apache ConstantsTable.pm FunctionTable.pm StructureTable.pm xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.24 +2 -1 modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm Index: ConstantsTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- ConstantsTable.pm 29 Mar 2002 16:16:20 - 1.23 +++ ConstantsTable.pm 6 Apr 2002 00:39:59 - 1.24 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Fri Mar 29 06:55:58 2002 +# ! Fri Apr 5 13:00:31 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -240,6 +240,7 @@ 'APR_LOCK_FLOCK', 'APR_LOCK_SYSVSEM', 'APR_LOCK_PROC_PTHREAD', + 'APR_LOCK_POSIXSEM', 'APR_LOCK_DEFAULT' ], 'limit' => [ 1.36 +1 -6 modperl-2.0/xs/tables/current/Apache/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/FunctionTable.pm,v retrieving revision 1.35 retrieving revision 1.36 diff -u -r1.35 -r1.36 --- FunctionTable.pm 29 Mar 2002 16:16:20 - 1.35 +++ FunctionTable.pm 6 Apr 2002 00:39:59 - 1.36 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Fri Mar 29 06:55:29 2002 +# ! Fri Apr 5 13:00:37 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -5139,11 +5139,6 @@ 'name' => 'bb' } ] - }, - { -'return_type' => 'void', -'name' => 'ap_sync_scoreboard_image', -'args' => [] }, { 'return_type' => 'void', 1.32 +24 -3 modperl-2.0/xs/tables/current/Apache/StructureTable.pm Index: StructureTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/StructureTable.pm,v retrieving revision 1.31 retrieving revision 1.32 diff -u -r1.31 -r1.32 --- StructureTable.pm 29 Mar 2002 16:16:20 - 1.31 +++ StructureTable.pm 6 Apr 2002 00:39:59 - 1.32 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Fri Mar 29 06:56:05 2002 +# ! Fri Apr 5 13:00:38 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -1144,7 +1144,7 @@ 'type' => 'apr_bucket', 'elts' => [ { -'type' => '_ANON 69', +'type' => '_ANON 70', 'name' => 'link' }, { @@ -1276,6 +1276,10 @@ ] }, { +'type' => 'apr_bucket_structs', +'elts' => [] + }, + { 'type' => 'apr_bucket_type_t', 'elts' => [ { @@ -1655,7 +1659,24 @@ }, { 'type' => 'apr_memnode_t', -'elts' => [] +'elts' => [ + { +'type' => 'apr_memnode_t *', +'name' => 'next' + }, + { +'type' => 'apr_uint32_t', +'name' => 'index' + }, + { +'type' => 'char *', +'name' => 'first_avail' + }, + { +'type' => 'char *', +'name' => 'endp' + } +] }, { 'type' => 'apr_mmap_t', 1.61 +5 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.60 retrieving revision 1.61 diff -u -r1.60 -r1.61 --- FunctionTable.pm 29 Mar 2002 16:16:20 - 1.60 +++ FunctionTable.pm 6 Apr 2002 00:40:00 - 1.61 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Fri Mar 29 06:56:16 2002 +# ! Fri Apr 5 13:00:51 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -5074,6 +5074,10 @@ { 'type' => 'apr_pool_t *', 'name' => 'p' + }, + { +'type' => 'apr_bucket_alloc_t *', +'name' => 'ba' } ] },
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 02/03/29 08:16:21 Modified:xs/tables/current/Apache ConstantsTable.pm FunctionTable.pm StructureTable.pm xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.23 +12 -1 modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm Index: ConstantsTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- ConstantsTable.pm 10 Mar 2002 00:17:05 - 1.22 +++ ConstantsTable.pm 29 Mar 2002 16:16:20 - 1.23 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Sat Mar 9 16:13:55 2002 +# ! Fri Mar 29 06:55:58 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -59,6 +59,17 @@ 'M_MOVE', 'M_LOCK', 'M_UNLOCK', + 'M_VERSION_CONTROL', + 'M_CHECKOUT', + 'M_UNCHECKOUT', + 'M_CHECKIN', + 'M_UPDATE', + 'M_LABEL', + 'M_REPORT', + 'M_MKWORKSPACE', + 'M_MKACTIVITY', + 'M_BASELINE_CONTROL', + 'M_MERGE', 'M_INVALID', 'METHODS' ], 1.35 +301 -43 modperl-2.0/xs/tables/current/Apache/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/FunctionTable.pm,v retrieving revision 1.34 retrieving revision 1.35 diff -u -r1.34 -r1.35 --- FunctionTable.pm 10 Mar 2002 00:17:05 - 1.34 +++ FunctionTable.pm 29 Mar 2002 16:16:20 - 1.35 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Sat Mar 9 16:14:02 2002 +# ! Fri Mar 29 06:55:29 2002 # ! do NOT edit, any changes will be lost ! # !! @@ -195,6 +195,16 @@ }, { 'return_type' => 'void', +'name' => 'ap_add_output_filters_by_type', +'args' => [ + { +'type' => 'request_rec *', +'name' => 'r' + } +] + }, + { +'return_type' => 'void', 'name' => 'ap_add_per_dir_conf', 'args' => [ { @@ -340,6 +350,10 @@ { 'type' => 'apr_pool_t *', 'name' => 'p' + }, + { +'type' => 'apr_bucket_alloc_t *', +'name' => 'list' } ] }, @@ -2964,6 +2978,10 @@ 'name' => 'ap_method_name_of', 'args' => [ { +'type' => 'apr_pool_t *', +'name' => 'p' + }, + { 'type' => 'int', 'name' => 'methnum' } @@ -3620,6 +3638,20 @@ ] }, { +'return_type' => 'apr_status_t', +'name' => 'ap_recent_ctime', +'args' => [ + { +'type' => 'char *', +'name' => 'date_str' + }, + { +'type' => 'apr_time_t', +'name' => 't' + } +] + }, + { 'return_type' => 'void', 'name' => 'ap_reclaim_child_processes', 'args' => [ @@ -3854,7 +3886,7 @@ }, { 'return_type' => 'apr_status_t', -'name' => 'ap_rgetline', +'name' => 'ap_rgetline_core', 'args' => [ { 'type' => 'char **', @@ -4005,6 +4037,10 @@ { 'type' => 'void *', 'name' => 'sbh' + }, + { +'type' => 'apr_bucket_alloc_t *', +'name' => 'alloc' } ] }, @@ -4286,6 +4322,10 @@ { 'type' => 'request_rec *', 'name' => 'r' + }, + { +'type' => 'int', +'name' => 'lookup_uri' } ] }, @@ -4413,6 +4453,24 @@ }, { 'return_type' => 'int', +'name' => 'ap_scan_script_header_err_brigade', +'args' => [ + { +'type' => 'request_rec *', +'name' => 'r' + }, + { +'type' => 'apr_bucket_brigade *', +'name' => 'bb' + }, + { +'type' => 'char *', +'name' => 'buffer' + } +] + }, + { +'return_type' => 'int', 'name' => 'ap_scan_script_header_err_core', 'args' => [ { @@ -4570,6 +4628,20 @@ ] }, { +'return_type' => 'void', +'name' => 'ap_set_content_type', +'args' => [ + { +'type' => 'request_rec *', +'name' => 'r' + }, + { +'type' => 'const char *', +'name' => 'ct' + } +] + }, + {
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 01/05/22 13:45:48 Modified:xs/tables/current/Apache ConstantsTable.pm FunctionTable.pm StructureTable.pm xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.8 +4 -1 modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm Index: ConstantsTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/ConstantsTable.pm,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- ConstantsTable.pm 2001/05/03 22:24:04 1.7 +++ ConstantsTable.pm 2001/05/22 20:45:33 1.8 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Thu May 3 15:00:16 2001 +# ! Tue May 22 13:17:31 2001 # ! do NOT edit, any changes will be lost ! # !! @@ -260,6 +260,8 @@ 'APR_EINCOMPLETE', 'APR_EABOVEROOT', 'APR_EBADPATH', + 'APR_ENOCLEANUP', + 'APR_EMEMSYS', 'APR_EOF', 'APR_EINIT', 'APR_ENOTIMPL', @@ -286,6 +288,7 @@ 'APR_ETIMEDOUT', 'APR_EHOSTUNREACH', 'APR_ENETUNREACH', + 'APR_EFTYPE', 'APR_END' ], 'finfo' => [ 1.7 +660 -336 modperl-2.0/xs/tables/current/Apache/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/FunctionTable.pm,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- FunctionTable.pm 2001/05/05 17:38:31 1.6 +++ FunctionTable.pm 2001/05/22 20:45:36 1.7 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Sat May 5 10:26:37 2001 +# ! Tue May 22 13:17:37 2001 # ! do NOT edit, any changes will be lost ! # !! @@ -1523,7 +1523,7 @@ }, { 'name' => 'klen', -'type' => 'apr_size_t *' +'type' => 'apr_ssize_t *' }, { 'name' => 'val', @@ -1843,7 +1843,7 @@ }, { 'name' => 'inputLen', -'type' => 'unsigned int' +'type' => 'apr_size_t' } ], 'name' => 'apr_md5_update' @@ -3183,11 +3183,6 @@ 'name' => 'apr_proc_other_child_check' }, { -'return_type' => 'void', -'args' => [], -'name' => 'apr_proc_probe_writable_fds' - }, - { 'return_type' => 'apr_status_t', 'args' => [ { @@ -3887,7 +3882,7 @@ }, { 'name' => 'len', -'type' => 'size_t' +'type' => 'apr_size_t' }, { 'name' => 'format', @@ -3909,7 +3904,7 @@ }, { 'name' => 'len', -'type' => 'size_t' +'type' => 'apr_size_t' }, { 'name' => 'format', @@ -5375,36 +5370,6 @@ 'name' => 'apr_hook_deregister_all' }, { -'return_type' => 'int', -'args' => [ - { -'name' => 'db', -'type' => 'apr_sdbm_t *' - } -], -'name' => 'apr_sdbm_rdonly' - }, - { -'return_type' => 'apr_status_t', -'args' => [ - { -'name' => 'db', -'type' => 'apr_sdbm_t *' - } -], -'name' => 'apr_sdbm_error_get' - }, - { -'return_type' => 'void', -'args' => [ - { -'name' => 'db', -'type' => 'apr_sdbm_t *' - } -], -'name' => 'apr_sdbm_error_clear' - }, - { 'return_type' => 'apr_status_t', 'args' => [ { @@ -5412,11 +5377,11 @@ 'type' => 'apr_sdbm_t **' }, { -'name' => 'filename', +'name' => 'name', 'type' => 'const char *' }, { -'name' => 'flags', +'name' => 'mode', 'type' => 'apr_int32_t' }, { @@ -5448,15 +5413,21 @@ 'type' => 'apr_sdbm_t *' }, { -'name' => 'val', -'type' => 'apr_sdbm_datum_t *' - }, +'name' => 'type', +'type' => 'int' + } +], +'name' => 'apr_sdbm_lock' + }, + { +'return_type' => 'apr_status_t', +'args' => [ { -'name' => 'key', -'type' => 'apr_sdbm_datum_t' +'name' => 'db', +'type' => 'apr_sdbm_t *' } ], -'name' => 'apr_sdbm_fetch' +'name' => 'apr_sdbm_unlock' }, { 'return_type' => 'apr_status_t', @@ -5466,11 +5437,15 @@
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 01/05/05 12:24:44 Modified:xs/Apache/RequestIO Apache__RequestIO.h xs/maps apache_functions.map modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Added: t/response/TestApache write.pm Log: add $r->write method (and WRITE alias) Revision ChangesPath 1.1 modperl-2.0/t/response/TestApache/write.pm Index: write.pm === package TestApache::write; use strict; use warnings FATAL => 'all'; use constant BUFSIZ => 512; #small for testing sub handler { my $r = shift; $r->content_type('text/plain'); $r->write("1..2"); $r->write("\n", 1); my $ok = "ok 1\n"; $r->write($ok, 2); $r->write($ok, -1, 2); $ok = "not ok 2\n"; $r->write($ok, 5, 4); 0; } 1; 1.10 +28 -0 modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h Index: Apache__RequestIO.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- Apache__RequestIO.h 2001/05/05 18:46:14 1.9 +++ Apache__RequestIO.h 2001/05/05 19:24:42 1.10 @@ -53,6 +53,34 @@ return bytes; } +/* alias */ +#define mpxs_Apache__RequestRec_WRITE mpxs_Apache__RequestRec_write + +static MP_INLINE +apr_ssize_t mpxs_Apache__RequestRec_write(request_rec *r, + SV *buffer, apr_ssize_t bufsiz, + int offset) +{ +dTHX; /*XXX*/ +apr_ssize_t wlen = bufsiz; +const char *buf; +STRLEN svlen; +MP_dRCFG; + +buf = (const char *)SvPV(buffer, svlen); + +if (bufsiz == -1) { +wlen = offset ? svlen - offset : svlen; +} +else { +wlen = bufsiz; +} + +modperl_wbucket_write(&rcfg->wbucket, buf+offset, &wlen); + +return wlen; +} + static MP_INLINE long mpxs_ap_get_client_block(pTHX_ request_rec *r, SV *buffer, int bufsiz) { 1.24 +1 -1 modperl-2.0/xs/maps/apache_functions.map Index: apache_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/apache_functions.map,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- apache_functions.map 2001/05/05 17:40:26 1.23 +++ apache_functions.map 2001/05/05 19:24:43 1.24 @@ -79,7 +79,7 @@ ap_should_client_block ap_rflush PREFIX=ap_r - ap_rwrite | | r, buf, nbyte +~ap_rwrite ~ap_rprintf !ap_rputc ~ap_rputs 1.15 +3 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- modperl_functions.map 2001/05/05 18:46:15 1.14 +++ modperl_functions.map 2001/05/05 19:24:43 1.15 @@ -19,6 +19,9 @@ mpxs_Apache__RequestRec_sendfile | | r, filename=r->filename, offset=0, len=0 mpxs_Apache__RequestRec_read | | r, buffer, bufsiz, offset=0 long:DEFINE_READ | | request_rec *:r, SV *:buffer, int:bufsiz, int:offset=0 + mpxs_Apache__RequestRec_write | | r, buffer, bufsiz=-1, offset=0 + apr_ssize_t:DEFINE_WRITE | | \ + request_rec *:r, SV *:buffer, apr_ssize_t:bufsiz=-1, int:offset=0 MODULE=Apache::ServerUtil PACKAGE=guess mpxs_Apache__Server_push_handlers 1.16 +23 -1 modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- FunctionTable.pm 2001/05/05 18:46:15 1.15 +++ FunctionTable.pm 2001/05/05 19:24:44 1.16 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by ModPerl::ParseSource/0.01 -# ! Sat May 5 10:40:17 2001 +# ! Sat May 5 12:17:55 2001 # ! do NOT edit, any changes will be lost ! # !! @@ -3680,6 +3680,28 @@ } ], 'name' => 'mpxs_ap_rvputs' + }, + { +'return_type' => 'apr_ssize_t', +'args' => [ + { +'name' => 'r', +'type' => 'request_rec *' + }, + { +'name' => 'buffer', +'type' => 'SV *' + }, + { +'name' =
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 01/05/05 11:46:15 Modified:xs/Apache/RequestIO Apache__RequestIO.h xs/maps modperl_functions.map xs/tables/current/ModPerl FunctionTable.pm Added: t/apache read.t t/response/TestApache read.pm Log: add $r->read method (and READ alias) Revision ChangesPath 1.1 modperl-2.0/t/apache/read.t Index: read.t === use strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestRequest; plan tests => 1; my $location = "/TestApache::read"; my $socket = Apache::TestRequest::vhost_socket('default'); $socket->autoflush(1); my $file = '../pod/modperl_2.0.pod'; open(my $fh, $file) or die "open $file: $!"; my $data = join '', <$fh>; close $fh; my $size = length $data; print $socket "POST $location http/1.0\r\n"; print $socket "Content-length: $size\r\n"; print $socket "\r\n"; my $written = 0; my $bufsiz = 240; my $sleeps = 2; while ($written < length($data)) { my $remain = length($data) - $written; my $len = $remain > $bufsiz ? $bufsiz : $remain; $written += syswrite($socket, $data, $len, $written); sleep 1 if $sleeps-- > 0; } while (<$socket>) { last if /^\015?\012$/; #skip over headers } my $return = join '', <$socket>; ok $data eq $return; 1.1 modperl-2.0/t/response/TestApache/read.pm Index: read.pm === package TestApache::read; use strict; use warnings FATAL => 'all'; use constant BUFSIZ => 512; #small for testing sub handler { my $r = shift; $r->content_type('text/plain'); my $ct = $r->headers_in->get('content-length'); my $buffer = ""; my $bufsiz = $r->args || BUFSIZ; while ((my($offset) = length($buffer)) < $ct) { my $remain = $ct - $offset; my $len = $remain >= $bufsiz ? $bufsiz : $remain; last unless $len > 0; $r->read($buffer, $len, $offset); } #make sure we dont block after all data is read my $n = $r->read(my $x, BUFSIZ); die unless $n == 0; $r->puts($buffer); 0; } 1; 1.9 +41 -0 modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h Index: Apache__RequestIO.h === RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- Apache__RequestIO.h 2001/05/05 02:16:03 1.8 +++ Apache__RequestIO.h 2001/05/05 18:46:14 1.9 @@ -73,6 +73,47 @@ return nrd; } +/* alias */ +#define mpxs_Apache__RequestRec_READ mpxs_Apache__RequestRec_read + +static long mpxs_Apache__RequestRec_read(request_rec *r, + SV *buffer, int bufsiz, + int offset) +{ +dTHX; /*XXX*/ +long nrd = 0, old_read_length; +int rc; + +if (!r->read_length) { +if ((rc = ap_setup_client_block(r, REQUEST_CHUNKED_ERROR)) != OK) { +ap_log_error(APLOG_MARK, APLOG_ERR|APLOG_NOERRNO, 0, + r->server, + "mod_perl: ap_setup_client_block failed: %d", rc); +return 0; +} +} + +old_read_length = r->read_length; +r->read_length = 0; + +if (ap_should_client_block(r)) { +mpxs_sv_grow(buffer, bufsiz+SvCUR(buffer)); +nrd = ap_get_client_block(r, SvPVX(buffer)+offset, bufsiz); +} + +r->read_length += old_read_length; + +if (nrd > 0) { +mpxs_sv_cur_set(buffer, nrd+offset); +SvTAINTED_on(buffer); +} +else { +sv_setsv(buffer, &PL_sv_undef); +} + +return nrd; +} + static MP_INLINE apr_status_t mpxs_Apache__RequestRec_sendfile(request_rec *r, const char *filename, 1.14 +2 -0 modperl-2.0/xs/maps/modperl_functions.map Index: modperl_functions.map === RCS file: /home/cvs/modperl-2.0/xs/maps/modperl_functions.map,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- modperl_functions.map 2001/05/04 04:21:54 1.13 +++ modperl_functions.map 2001/05/05 18:46:15 1.14 @@ -17,6 +17,8 @@ SV *:DEFINE_TIEHANDLE | | SV *:stashsv, SV *:sv=Nullsv apr_size_t:DEFINE_PRINT | | ... mpxs_Apache__RequestRec_sendfile | | r, filename=r->filename, offset=0, len=0 + mpxs_Apache__RequestRec_read | | r, buffer, bufsiz, offset=0 + long:DEFINE_READ | | request_rec *:r, SV *:buffer, int:buf
cvs commit: modperl-2.0/xs/tables/current/ModPerl FunctionTable.pm
dougm 01/05/05 10:38:33 Modified:xs/tables/current/Apache FunctionTable.pm StructureTable.pm xs/tables/current/ModPerl FunctionTable.pm Log: sync Revision ChangesPath 1.6 +157 -5modperl-2.0/xs/tables/current/Apache/FunctionTable.pm Index: FunctionTable.pm === RCS file: /home/cvs/modperl-2.0/xs/tables/current/Apache/FunctionTable.pm,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- FunctionTable.pm 2001/04/27 21:07:04 1.5 +++ FunctionTable.pm 2001/05/05 17:38:31 1.6 @@ -2,7 +2,7 @@ # !! # ! WARNING: generated by Apache::ParseSource/0.02 -# ! Fri Apr 27 14:00:21 2001 +# ! Sat May 5 10:26:37 2001 # ! do NOT edit, any changes will be lost ! # !! @@ -5123,7 +5123,11 @@ }, { 'name' => 'mode', -'type' => 'int' +'type' => 'apr_int32_t' + }, + { +'name' => 'perm', +'type' => 'apr_fileperms_t' }, { 'name' => 'cntxt', @@ -5371,9 +5375,157 @@ 'name' => 'apr_hook_deregister_all' }, { +'return_type' => 'int', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + } +], +'name' => 'apr_sdbm_rdonly' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + } +], +'name' => 'apr_sdbm_error_get' + }, + { 'return_type' => 'void', 'args' => [ { +'name' => 'db', +'type' => 'apr_sdbm_t *' + } +], +'name' => 'apr_sdbm_error_clear' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t **' + }, + { +'name' => 'filename', +'type' => 'const char *' + }, + { +'name' => 'flags', +'type' => 'apr_int32_t' + }, + { +'name' => 'perms', +'type' => 'apr_fileperms_t' + }, + { +'name' => 'p', +'type' => 'apr_pool_t *' + } +], +'name' => 'apr_sdbm_open' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + } +], +'name' => 'apr_sdbm_close' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + }, + { +'name' => 'val', +'type' => 'apr_sdbm_datum_t *' + }, + { +'name' => 'key', +'type' => 'apr_sdbm_datum_t' + } +], +'name' => 'apr_sdbm_fetch' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + }, + { +'name' => 'key', +'type' => 'const apr_sdbm_datum_t' + } +], +'name' => 'apr_sdbm_delete' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + }, + { +'name' => 'key', +'type' => 'apr_sdbm_datum_t' + }, + { +'name' => 'value', +'type' => 'apr_sdbm_datum_t' + }, + { +'name' => 'flags', +'type' => 'int' + } +], +'name' => 'apr_sdbm_store' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + }, + { +'name' => 'key', +'type' => 'apr_sdbm_datum_t *' + } +], +'name' => 'apr_sdbm_firstkey' + }, + { +'return_type' => 'apr_status_t', +'args' => [ + { +'name' => 'db', +'type' => 'apr_sdbm_t *' + }, + { +'name' => 'key', +'type' => 'apr_sdbm_datum_t *' + } +], +'name' => 'apr_sdbm_nextkey' + }, + { +'return_type' => 'void', +'args' => [ + { 'name' => 'clear', 'type' => 'const char *' }, @@ -6316,7 +6468,7 @@ 'return_type' => 'int', 'args' => [ { -'name' => 'arg0', +'name' => 'r', 'type' => 'request_rec *' } ], @@ -7929,7 +8081,7 @@ 'type' => 'apr_status_t' }, { -'name' => 's', +'name' => 'r', 'type' => 'const request_rec *' }, { @