cvs commit: modperl-2.0/t/conf modperl_extra.pl
dougm 2002/09/04 18:49:32 Modified:t/conf modperl_extra.pl Log: test $r-add_config Revision ChangesPath 1.19 +14 -5 modperl-2.0/t/conf/modperl_extra.pl Index: modperl_extra.pl === RCS file: /home/cvs/modperl-2.0/t/conf/modperl_extra.pl,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- modperl_extra.pl 24 Aug 2002 16:33:15 - 1.18 +++ modperl_extra.pl 5 Sep 2002 01:49:32 - 1.19 -62,6 +62,16 return $buf; } +sub ModPerl::Test::add_config { +my $r = shift; + +#test adding config at request time +my $errmsg = $r-add_config(['require valid-user']); +die $errmsg if $errmsg; + +Apache::OK; +} + #Perl handler=ModPerl::Test::perl_section # ... #/Perl -77,23 +87,22 ## a real handler would do something like: #eval package $package; $code; #die $ if $; -## feed %Apache::ReadConfig:: to Apache::Directive-insert +## feed %Apache::ReadConfig:: to Apache::Server-add_config my $htdocs = Apache::server_root_relative($parms-pool, 'htdocs'); my cfg = ( Alias /perl_sections $htdocs, Location /perl_sections, - require valid-user, +# require valid-user, + PerlInitHandler ModPerl::Test::add_config, AuthType Basic, AuthName PerlSection, PerlAuthenHandler TestHooks::authen, /Location, ); -my $errmsg = Apache::Directive-insert($parms-server, - $parms-pool, - \@cfg); +my $errmsg = $parms-server-add_config(\@cfg); die $errmsg if $errmsg;
cvs commit: modperl-2.0/t/conf modperl_extra.pl
dougm 02/05/23 15:40:48 Modified:lib/APR XSLoader.pm lib/Apache XSLoader.pm src/modules/perl mod_perl.c modperl_perl_includes.h t/conf modperl_extra.pl Log: better workaround for 5.6.x DynaLoader vs. XSLoader issue Revision ChangesPath 1.3 +0 -1 modperl-2.0/lib/APR/XSLoader.pm Index: XSLoader.pm === RCS file: /home/cvs/modperl-2.0/lib/APR/XSLoader.pm,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- XSLoader.pm 16 Apr 2002 23:29:18 - 1.2 +++ XSLoader.pm 23 May 2002 22:40:47 - 1.3 -3,7 +3,6 use strict; use warnings FATAL = 'all'; -use DynaLoader (); #XXX workaround for 5.6.1 bug use XSLoader (); BEGIN { 1.3 +0 -1 modperl-2.0/lib/Apache/XSLoader.pm Index: XSLoader.pm === RCS file: /home/cvs/modperl-2.0/lib/Apache/XSLoader.pm,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- XSLoader.pm 16 Apr 2002 23:29:18 - 1.2 +++ XSLoader.pm 23 May 2002 22:40:47 - 1.3 -3,7 +3,6 use strict; use warnings FATAL = 'all'; -use DynaLoader (); #XXX workaround for 5.6.1 bug use XSLoader (); BEGIN { 1.118 +8 -0 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.117 retrieving revision 1.118 diff -u -r1.117 -r1.118 --- mod_perl.c23 May 2002 17:30:26 - 1.117 +++ mod_perl.c23 May 2002 22:40:47 - 1.118 -119,6 +119,14 newCONSTSUB(PL_defstash, Apache::MPM_IS_THREADED, newSViv(scfg-threaded_mpm)); + +#ifdef MP_PERL_5_6_x +/* make sure DynaLoader is loaded before XSLoader + * to workaround bug in 5.6.1 that can trigger a segv + * when using modperl as a dso + */ +modperl_require_module(aTHX_ DynaLoader, FALSE); +#endif } static void modperl_xs_init(pTHX) 1.12 +5 -1 modperl-2.0/src/modules/perl/modperl_perl_includes.h Index: modperl_perl_includes.h === RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_perl_includes.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- modperl_perl_includes.h 11 May 2002 18:55:41 - 1.11 +++ modperl_perl_includes.h 23 May 2002 22:40:47 - 1.12 -40,7 +40,11 #include perl.h #include XSUB.h -#if (PERL_REVISION == 5) (PERL_VERSION == 6) (PERL_SUBVERSION == 1) +#if (PERL_REVISION == 5) (PERL_VERSION == 6) +# define MP_PERL_5_6_x +#endif + +#if defined(MP_PERL_5_6_x) (PERL_SUBVERSION == 1) # define MP_PERL_5_6_1 #endif 1.16 +3 -0 modperl-2.0/t/conf/modperl_extra.pl Index: modperl_extra.pl === RCS file: /home/cvs/modperl-2.0/t/conf/modperl_extra.pl,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- modperl_extra.pl 18 May 2002 02:14:47 - 1.15 +++ modperl_extra.pl 23 May 2002 22:40:47 - 1.16 -1,3 +1,6 +use Socket (); #test DynaLoader vs. XSLoader workaround for 5.6.x +use IO::File (); + use Apache2 (); use ModPerl::Util (); #for CORE::GLOBAL::exit
cvs commit: modperl-2.0/t/conf modperl_extra.pl
dougm 02/05/17 19:08:21 Modified:t/conf modperl_extra.pl Log: add config for modperl/methodobj test Revision ChangesPath 1.14 +4 -0 modperl-2.0/t/conf/modperl_extra.pl Index: modperl_extra.pl === RCS file: /home/cvs/modperl-2.0/t/conf/modperl_extra.pl,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- modperl_extra.pl 6 Apr 2002 01:42:53 - 1.13 +++ modperl_extra.pl 18 May 2002 02:08:21 - 1.14 -22,6 +22,10 die '$ENV{MOD_PERL} not set!'; } +#see t/modperl/methodobj +use TestModperl::methodobj (); +$TestModperl::MethodObj = bless {}, 'TestModperl::methodobj'; + #see t/response/TestModperl/env.pm $ENV{MODPERL_EXTRA_PL} = __FILE__;
cvs commit: modperl-2.0/t/conf modperl_extra.pl
dougm 01/04/19 13:20:41 Modified:t/conf modperl_extra.pl Log: compile common APR constants Revision ChangesPath 1.4 +1 -0 modperl-2.0/t/conf/modperl_extra.pl Index: modperl_extra.pl === RCS file: /home/cvs/modperl-2.0/t/conf/modperl_extra.pl,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- modperl_extra.pl 2001/04/19 17:32:27 1.3 +++ modperl_extra.pl 2001/04/19 20:20:37 1.4 @@ -5,6 +5,7 @@ use Apache::Connection (); use Apache::Const -compile = ':common'; +use APR::Const -compile = ':common'; use APR::Table ();
cvs commit: modperl-2.0/t/conf modperl_extra.pl
dougm 01/04/12 18:49:58 Modified:t/conf modperl_extra.pl Log: compile common constants at startup so we dont need to in each test module Revision ChangesPath 1.2 +2 -0 modperl-2.0/t/conf/modperl_extra.pl Index: modperl_extra.pl === RCS file: /home/cvs/modperl-2.0/t/conf/modperl_extra.pl,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- modperl_extra.pl 2001/04/02 09:10:18 1.1 +++ modperl_extra.pl 2001/04/13 01:49:58 1.2 @@ -4,4 +4,6 @@ use Apache::Server (); use Apache::Connection (); +use Apache::Const -compile = ':common'; + 1;