Geoffrey Young wrote:
$Apache::PerlSections::Strict
whoops - that's gone now. I guess I haven't sync'd my checkout in a while :)
$Apache::PerlSections::Save
+1!
+1 from me too, these configuration variables were 'ported' from mp1 to mp2 as is. And sticking them in $Apache::Server::** didn't make much sense.
Good idea Geoff!
and compat.pod to be updated :)
partial patch attached - I'm getting some failures in perldo.t that I can't figure out, but it's probably because I have no business messing around in gozerland ;)
Thanks for the patch Geoff, I'll sort it all out today!
--Geoff
------------------------------------------------------------------------
Index: docs/api/Apache/PerlSections.pod
===================================================================
RCS file: /home/cvs/modperl-docs/src/docs/2.0/api/Apache/PerlSections.pod,v
retrieving revision 1.17
diff -u -r1.17 PerlSections.pod
--- docs/api/Apache/PerlSections.pod 15 Aug 2004 00:53:31 -0000 1.17
+++ docs/api/Apache/PerlSections.pod 23 Aug 2004 19:46:56 -0000
@@ -138,7 +138,7 @@
-=head2 C<$Apache::Server::SaveConfig>
+=head2 C<$Apache::PerlSections::Save>
By default, the namespace in which C<E<lt>Perl E<gt>> sections are
evaluated is cleared after each block closes. By setting it to a true
Index: docs/user/intro/overview.pod
===================================================================
RCS file: /home/cvs/modperl-docs/src/docs/2.0/user/intro/overview.pod,v
retrieving revision 1.4
diff -u -r1.4 overview.pod
--- docs/user/intro/overview.pod 11 Apr 2003 02:24:37 -0000 1.4
+++ docs/user/intro/overview.pod 23 Aug 2004 19:46:58 -0000
@@ -269,7 +269,7 @@
there are two approaches. A module can "subclass" directive handlers,
saving a copy of the data for itself, then returning B<DECLINE_CMD> so
the other modules are also handed the info. Or, the
-C<$Apache::Server::SaveConfig> variable can be set to save
+C<$Apache::PerlSections::Save> variable can be set to save
E<lt>PerlE<gt> configuration in the C<%Apache::ReadConfig::>
namespace. Both methods are rather kludgy, version 2.0 provides a
L<Perl interface to the Apache configuration
Index: docs/user/porting/compat.pod
===================================================================
RCS file: /home/cvs/modperl-docs/src/docs/2.0/user/porting/compat.pod,v
retrieving revision 1.60
diff -u -r1.60 compat.pod
--- docs/user/porting/compat.pod 5 Aug 2004 17:17:15 -0000 1.60
+++ docs/user/porting/compat.pod 23 Aug 2004 19:47:00 -0000
@@ -92,6 +92,13 @@
can be used to trap errors and ignore them. In mod_perl 1, 'strict' was
somewhat of a misnomer.
+=head2 C<$Apache::Server::SaveConfig>
+
+C<$Apache::Server::SaveConfig> has been renamed to
+C<$Apache::PerlSections::Save>. see
+C<L<E<lt>PerlE<gt>|docs::2.0::api::Apache::PerlSections>>
+for more information on this global variable.
+
=head2 Apache Configuration Customization
mod_perl 2.0 has slightly changed the mechanism for L<adding custom
Index: lib/Apache/PerlSections.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/lib/Apache/PerlSections.pm,v
retrieving revision 1.6
diff -u -r1.6 PerlSections.pm
--- lib/Apache/PerlSections.pm 9 Aug 2004 00:17:05 -0000 1.6
+++ lib/Apache/PerlSections.pm 23 Aug 2004 19:47:00 -0000
@@ -39,7 +39,7 @@
sub package { return shift->{'args'}->{'package'} }
my @saved;
-sub save { return $Apache::Server::SaveConfig }
+sub save { return $Apache::PerlSections::Save }
sub saved { return @saved }
sub handler : method {
Index: lib/Apache/Status.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/lib/Apache/Status.pm,v
retrieving revision 1.27
diff -u -r1.27 Status.pm
--- lib/Apache/Status.pm 16 Jul 2004 01:10:45 -0000 1.27
+++ lib/Apache/Status.pm 23 Aug 2004 19:47:00 -0000
@@ -67,7 +67,7 @@
delete $status{'sig'} if IS_WIN32;
# XXX: needs porting
-if ($Apache::Server::SaveConfig) {
+if ($Apache::PerlSections::Save) {
$status{"section_config"} = "Perl Section Configuration";
}
Index: src/modules/perl/modperl_cmd.c
===================================================================
RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_cmd.c,v
retrieving revision 1.63
diff -u -r1.63 modperl_cmd.c
--- src/modules/perl/modperl_cmd.c 7 Aug 2004 03:09:05 -0000 1.63
+++ src/modules/perl/modperl_cmd.c 23 Aug 2004 19:47:02 -0000
@@ -482,7 +482,7 @@
#define MP_DEFAULT_PERLSECTION_HANDLER "Apache::PerlSections"
#define MP_DEFAULT_PERLSECTION_PACKAGE "Apache::ReadConfig"
#define MP_PERLSECTIONS_SAVECONFIG_SV \
- get_sv("Apache::Server::SaveConfig", FALSE)
+ get_sv("Apache::PerlSections::Save", FALSE)
MP_CMD_SRV_DECLARE(perldo)
{
Index: t/conf/extra.last.conf.in
===================================================================
RCS file: /home/cvs/modperl-2.0/t/conf/extra.last.conf.in,v
retrieving revision 1.23
diff -u -r1.23 extra.last.conf.in
--- t/conf/extra.last.conf.in 8 Aug 2004 23:50:48 -0000 1.23
+++ t/conf/extra.last.conf.in 23 Aug 2004 19:47:02 -0000
@@ -17,7 +17,7 @@
tie %Location, 'ModPerl::TestTiePerlSection';
$Location{'/tied'} = 'test_tied';
-$Apache::Server::SaveConfig = 1;
+$Apache::PerlSections::Save = 1;
$Location{'/perl_sections_saved'} = {
'AuthName' => 'PerlSection',
};
@@ -27,7 +27,7 @@
</Perl>
<Perl >
-$Apache::Server::SaveConfig = 1;
+$Apache::PerlSections::Save = 1;
$TestDirective::perl::filename = __FILE__;
$TestDirective::perl::dollar_zero = $0;
$TestDirective::perl::line = __LINE__;
------------------------------------------------------------------------
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- -------------------------------------------------------------------------------- Philippe M. Chiasson m/gozer\@(apache|cpan|ectoplasm)\.org/ GPG KeyID : 88C3A5A5 http://gozer.ectoplasm.org/ F9BF E0C2 480E 7680 1AE5 3631 CB32 A107 88C3A5A5
signature.asc
Description: OpenPGP digital signature