svn commit: r690793 - /perl/modperl/branches/1.x/mod_perl.pod

2008-08-31 Thread stas
Author: stas
Date: Sun Aug 31 15:06:42 2008
New Revision: 690793

URL: http://svn.apache.org/viewvc?rev=690793view=rev
Log:
Indicate that http://perl.apache.org/faq/ is no more and merged into the docs
Reported by: Lars Noodén [EMAIL PROTECTED]

Modified:
perl/modperl/branches/1.x/mod_perl.pod

Modified: perl/modperl/branches/1.x/mod_perl.pod
URL: 
http://svn.apache.org/viewvc/perl/modperl/branches/1.x/mod_perl.pod?rev=690793r1=690792r2=690793view=diff
==
--- perl/modperl/branches/1.x/mod_perl.pod (original)
+++ perl/modperl/branches/1.x/mod_perl.pod Sun Aug 31 15:06:42 2008
@@ -36,8 +36,9 @@
 
 =head1 FAQ
 
-The mod_perl FAQ is maintained by Frank Cringle
-Elt[EMAIL PROTECTED]gt: http://perl.apache.org/faq/
+The mod_perl FAQ that used to be maintained by Frank Cringle
+Elt[EMAIL PROTECTED]gt, had been merged into the mod_perl
+documentation that can be found http://perl.apache.org/docs/
 
 =head1 Apache/Perl API
 




svn commit: r503974 - /perl/modperl/trunk/src/modules/perl/modperl_handler.c

2007-02-05 Thread stas
Author: stas
Date: Mon Feb  5 20:14:28 2007
New Revision: 503974

URL: http://svn.apache.org/viewvc?view=revrev=503974
Log:
make the compiler happy (missing the 'default' case in the switch statement)

Modified:
perl/modperl/trunk/src/modules/perl/modperl_handler.c

Modified: perl/modperl/trunk/src/modules/perl/modperl_handler.c
URL: 
http://svn.apache.org/viewvc/perl/modperl/trunk/src/modules/perl/modperl_handler.c?view=diffrev=503974r1=503973r2=503974
==
--- perl/modperl/trunk/src/modules/perl/modperl_handler.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_handler.c Mon Feb  5 20:14:28 
2007
@@ -514,6 +514,7 @@
 }
 name = apr_pstrcat(p, HvNAME(GvSTASH(gv)), ::, GvNAME(gv), NULL);
 return modperl_handler_new(p, apr_pstrdup(p, name));
+  default:
 break;
 };
 




svn commit: r503976 - in /perl/modperl/trunk: Changes ModPerl-Registry/lib/ModPerl/RegistryCooker.pm

2007-02-05 Thread stas
Author: stas
Date: Mon Feb  5 20:31:48 2007
New Revision: 503976

URL: http://svn.apache.org/viewvc?view=revrev=503976
Log:
fix ModPerl::RegistryCooker::read_script to handle all possible
errors, previously there was a case where Apache2::Const::OK was
returned on an error. 
Contributed by: Eivind Eklund [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/modperl/trunk/Changes?view=diffrev=503976r1=503975r2=503976
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon Feb  5 20:31:48 2007
@@ -12,6 +12,13 @@
 
 =item 2.0.4-dev
 
+fix ModPerl::RegistryCooker::read_script to handle all possible
+errors, previously there was a case where Apache2::Const::OK was
+returned on an error.  [Eivind Eklund [EMAIL PROTECTED]]
+
+a minor compilation warning resolved in modperl_handler_new_from_sv
+[Stas]
+
 a minor compilation warning resolved in modperl_gtop_size_string
 [Stas]
 

Modified: perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm
URL: 
http://svn.apache.org/viewvc/perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm?view=diffrev=503976r1=503975r2=503976
==
--- perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm (original)
+++ perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm Mon Feb  
5 20:31:48 2007
@@ -546,9 +546,8 @@
 return Apache2::Const::FORBIDDEN if APR::Status::is_EACCES($@);
 return Apache2::Const::NOT_FOUND if APR::Status::is_ENOENT($@);
 }
-else {
-return Apache2::Const::SERVER_ERROR;
-}
+
+return Apache2::Const::SERVER_ERROR;
 }
 
 return Apache2::Const::OK;




svn commit: r483625 - in /perl/modperl/trunk: Changes src/modules/perl/modperl_gtop.c

2006-12-07 Thread stas
Author: stas
Date: Thu Dec  7 11:27:58 2006
New Revision: 483625

URL: http://svn.apache.org/viewvc?view=revrev=483625
Log:
a minor compilation warning resolved in modperl_gtop_size_string


Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_gtop.c

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/modperl/trunk/Changes?view=diffrev=483625r1=483624r2=483625
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Thu Dec  7 11:27:58 2006
@@ -12,6 +12,9 @@
 
 =item 2.0.4-dev
 
+a minor compilation warning resolved in modperl_gtop_size_string
+[Stas]
+
 Prevent direct use of _deprecated_ Apache2::ReadConfig in
 Perl sections with httpd Alias directives from 
 incorrectly generating

Modified: perl/modperl/trunk/src/modules/perl/modperl_gtop.c
URL: 
http://svn.apache.org/viewvc/perl/modperl/trunk/src/modules/perl/modperl_gtop.c?view=diffrev=483625r1=483624r2=483625
==
--- perl/modperl/trunk/src/modules/perl/modperl_gtop.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_gtop.c Thu Dec  7 11:27:58 2006
@@ -31,7 +31,7 @@
 }
 else if (size  1048576) {
 apr_snprintf(size_string, MP_GTOP_SSS, %dk,
- (size + 512) / 1024);
+ (int)(size + 512) / 1024);
 }
 else if (size  103809024) {
 apr_snprintf(size_string, MP_GTOP_SSS, %.1fM,
@@ -39,7 +39,7 @@
 }
 else {
 apr_snprintf(size_string, MP_GTOP_SSS, %dM,
- (size + 524288) / 1048576);
+ (int)(size + 524288) / 1048576);
 }
 
 return 1;




svn commit: r386498 - in /perl/modperl/trunk: Changes lib/ModPerl/BuildMM.pm xs/APR/APR/Makefile.PL

2006-03-16 Thread stas
Author: stas
Date: Thu Mar 16 16:40:43 2006
New Revision: 386498

URL: http://svn.apache.org/viewcvs?rev=386498view=rev
Log:
Make sure that LIBS and other MakeMaker command line flags are not
ignored by the top level Makefile.PL and xs/APR/APR/Makefile.PL

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/ModPerl/BuildMM.pm
perl/modperl/trunk/xs/APR/APR/Makefile.PL

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=386498r1=386497r2=386498view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Thu Mar 16 16:40:43 2006
@@ -12,6 +12,9 @@
 
 =item 2.0.3-dev
 
+Make sure that LIBS and other MakeMaker command line flags are not
+ignored by the top level Makefile.PL and xs/APR/APR/Makefile.PL [Stas]
+
 Corrected a typo that would cause the corruption of $), the
 effective group id as Perl sees it [Gozer]
 

Modified: perl/modperl/trunk/lib/ModPerl/BuildMM.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/BuildMM.pm?rev=386498r1=386497r2=386498view=diff
==
--- perl/modperl/trunk/lib/ModPerl/BuildMM.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/BuildMM.pm Thu Mar 16 16:40:43 2006
@@ -75,7 +75,9 @@
 $build ||= build_config();
 ModPerl::MM::my_import(__PACKAGE__);
 
-my $inc = $build-inc;
+my $inc;
+$inc = $args{INC} if $args{INC};
+$inc =   . $build-inc;
 if (my $glue_inc = $build-{MP_XS_GLUE_DIR}) {
 for (split /\s+/, $glue_inc) {
 $inc .=  -I$_;
@@ -84,6 +86,7 @@
 
 my $libs;
 my @libs = ();
+push @libs, $args{LIBS} if $args{LIBS};
 if (Apache2::Build::BUILD_APREXT) {
 # in order to decouple APR/APR::* from mod_perl.so,
 # link these modules against the static MP_APR_LIB lib,
@@ -105,18 +108,33 @@
 }
 $libs = join ' ', @libs;
 
-my $ccflags = $build-perl_ccopts . $build-ap_ccopts;
+my $ccflags;
+$ccflags = $args{CCFLAGS} if $args{CCFLAGS};
+$ccflags =   . $build-perl_ccopts . $build-ap_ccopts;
+
+my $optimize;
+$optimize = $args{OPTIMIZE} if $args{OPTIMIZE};
+$optimize =   . $build-perl_config('optimize');
+
+my $lddlflags;
+$lddlflags = $args{LDDLFLAGS} if $args{LDDLFLAGS};
+$lddlflags =   . $build-perl_config('lddlflags');
+
+my %dynamic_lib;
+%dynamic_lib = %{ $args{dynamic_lib}||{} } if $args{dynamic_lib};
+$dynamic_lib{OTHERLDFLAGS} = $build-otherldflags;
 
 my @opts = (
-INC   = $inc,
-CCFLAGS   = $ccflags,
-OPTIMIZE  = $build-perl_config('optimize'),
-LDDLFLAGS = $build-perl_config('lddlflags'),
-LIBS  = $libs,
-dynamic_lib = { OTHERLDFLAGS = $build-otherldflags },
+INC = $inc,
+CCFLAGS = $ccflags,
+OPTIMIZE= $optimize,
+LDDLFLAGS   = $lddlflags,
+LIBS= $libs,
+dynamic_lib = \%dynamic_lib,
 );
 
 my @typemaps;
+push @typemaps, $args{TYPEMAPS} if $args{TYPEMAPS};
 my $pwd = Cwd::fastcwd();
 for ('xs', $pwd, $pwd/..) {
 my $typemap = $build-file_path($_/typemap);

Modified: perl/modperl/trunk/xs/APR/APR/Makefile.PL
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/APR/APR/Makefile.PL?rev=386498r1=386497r2=386498view=diff
==
--- perl/modperl/trunk/xs/APR/APR/Makefile.PL (original)
+++ perl/modperl/trunk/xs/APR/APR/Makefile.PL Thu Mar 16 16:40:43 2006
@@ -13,12 +13,16 @@
 use constant SOLARIS = $^O eq 'solaris';
 use constant BUILD_APREXT   = Apache2::Build::BUILD_APREXT;
 
-my %args = (
-'NAME' = 'APR',
-'VERSION_FROM' = 'APR.pm',
-);
+my %args;
+
+%args = map { split /=/, $_ } @ARGV;
+
+$args{NAME} = 'APR';
+$args{VERSION_FROM} = 'APR.pm';
 
 my $libs = '';
+$libs = delete $args{LIBS} if $args{LIBS};
+
 my $build = ModPerl::BuildMM::build_config();
 
 my @apru_link_flags = $build-apru_link_flags;
@@ -53,7 +57,9 @@
 
 # -R makes sure that these paths will be used
 $extralddflags =~ s{-L(\S+)}{-L$1 -R$1}g;
-$args{LDDLFLAGS} = $extralddflags .   . $build-perl_config('lddlflags');
+$args{LDDLFLAGS} =  unless exists $args{LDDLFLAGS};
+$args{LDDLFLAGS} = join  , $args{LDDLFLAGS}, $extralddflags,
+$build-perl_config('lddlflags');
 
 # -R are now copied to LDDFLAGS, but leave -L's in LIBS --
 # EU::MM needs it.




svn commit: r381784 - /perl/modperl/trunk/build/svn.remerge

2006-02-28 Thread stas
Author: stas
Date: Tue Feb 28 13:16:27 2006
New Revision: 381784

URL: http://svn.apache.org/viewcvs?rev=381784view=rev
Log:
make the script more portable: sed parts didn't work on Solaris 9, use perl 
instead

Modified:
perl/modperl/trunk/build/svn.remerge

Modified: perl/modperl/trunk/build/svn.remerge
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/build/svn.remerge?rev=381784r1=381783r2=381784view=diff
==
--- perl/modperl/trunk/build/svn.remerge (original)
+++ perl/modperl/trunk/build/svn.remerge Tue Feb 28 13:16:27 2006
@@ -1,14 +1,18 @@
 #!/bin/bash
 # automatic SVN merging
+#
+# when used for the first time, first run:
+#  svn propset merge-point $revision
+# where $revision is the rev number when a branch was made
 
-root=`svn info . | sed -n '/^URL/{s,/branches/.*,,;s/^URL: //;p}'`
+root=`svn info . | perl -007 -ne 'm|URL: (.*?)/branches|s and print $1'`
 trunk=${root}/trunk
 
 # svn 1.2.x supports svn info URL.  Without that, a stupid
 # ls command is needed to find the current revision of the trunk
 #next=`svn info $trunk | sed -n '/^Revision: /{s/.*: //g;p}'`
 
-next=`svn ls --verbose $root | sed -n '/ trunk/{s/^ *//g;s/ .*//g;p}'`
+next=`svn ls --verbose $root | perl -ne 'm|^\s+(\d+).*trunk/$| and print $1'`
 last=`svn propget merge-point .`
 
 echo $0: merging from trunk from r$last to r$next




svn commit: r370270 - in /perl/modperl/trunk: Changes t/response/TestApache/daemon.pm xs/Apache2/ServerUtil/Apache2__ServerUtil.h xs/maps/modperl_functions.map

2006-01-18 Thread stas
Author: stas
Date: Wed Jan 18 13:47:36 2006
New Revision: 370270

URL: http://svn.apache.org/viewcvs?rev=370270view=rev
Log:
Add perl API corresponding to User and Group directives in httpd.conf: 
Apache2::ServerUtil-user_id and Apache2::ServerUtil-group_id

Added:
perl/modperl/trunk/t/response/TestApache/daemon.pm   (with props)
Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/xs/Apache2/ServerUtil/Apache2__ServerUtil.h
perl/modperl/trunk/xs/maps/modperl_functions.map

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=370270r1=370269r2=370270view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed Jan 18 13:47:36 2006
@@ -12,6 +12,10 @@
 
 =item 2.0.3-dev
 
+Add perl API corresponding to User and Group directives in httpd.conf: 
+Apache2::ServerUtil-user_id and Apache2::ServerUtil-group_id
+[Stas]
+
 Apache2::Reload now first unloads all modified modules before
 trying to reload them. This way, inter-module dependencies
 are more likely to be correctly satisfied when reloaded

Added: perl/modperl/trunk/t/response/TestApache/daemon.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestApache/daemon.pm?rev=370270view=auto
==
--- perl/modperl/trunk/t/response/TestApache/daemon.pm (added)
+++ perl/modperl/trunk/t/response/TestApache/daemon.pm Wed Jan 18 13:47:36 2006
@@ -0,0 +1,39 @@
+package TestApache::daemon;
+
+# Apache2::ServerUtil tests
+
+use strict;
+use warnings FATAL = 'all';
+
+use Apache2::ServerUtil ();
+
+use Apache::TestConfig ();
+use Apache::TestUtil;
+use Apache::Test;
+
+use constant WIN32 = Apache::TestConfig::WIN32 || Apache::TestConfig::CYGWIN;
+
+use Apache2::Const -compile = 'OK';
+
+sub handler {
+my $r = shift;
+
+plan $r, tests = 2;
+
+my $user_id = Apache2::ServerUtil-user_id;
+my $user_id_expected = WIN32 ? 0 : $;
+
+ok t_cmp $user_id, $user_id_expected, user id;
+
+my $group_id = Apache2::ServerUtil-group_id;
+my ($group_id_expected) = WIN32 ? 0 : ($( =~ /^(\d+)/);
+
+ok t_cmp $group_id, $group_id_expected, group id;
+
+Apache2::Const::OK;
+}
+
+1;
+
+__END__
+

Propchange: perl/modperl/trunk/t/response/TestApache/daemon.pm
--
svn:eol-style = native

Modified: perl/modperl/trunk/xs/Apache2/ServerUtil/Apache2__ServerUtil.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/Apache2/ServerUtil/Apache2__ServerUtil.h?rev=370270r1=370269r2=370270view=diff
==
--- perl/modperl/trunk/xs/Apache2/ServerUtil/Apache2__ServerUtil.h (original)
+++ perl/modperl/trunk/xs/Apache2/ServerUtil/Apache2__ServerUtil.h Wed Jan 18 
13:47:36 2006
@@ -13,6 +13,10 @@
  * limitations under the License.
  */
 
+#if !defined(OS2)  !defined(WIN32)  !defined(BEOS)   !defined(NETWARE)
+#include unixd.h
+#endif
+
 #define mpxs_Apache2__ServerUtil_restart_count modperl_restart_count
 
 #define mpxs_Apache2__ServerRec_method_register(s, methname) \
@@ -150,6 +154,14 @@
 modperl_dir_config(aTHX_ NULL, s, key, sv_val)
 
 #define mpxs_Apache2__ServerUtil_server(classname) 
modperl_global_get_server_rec()
+
+#if !defined(OS2)  !defined(WIN32)  !defined(BEOS)   !defined(NETWARE)
+#define mpxs_Apache2__ServerUtil_user_id(classname)  unixd_config.user_id
+#define mpxs_Apache2__ServerUtil_group_id(classname) unixd_config.group_id
+#else
+#define mpxs_Apache2__ServerUtil_user_id(classname)  0
+#define mpxs_Apache2__ServerUtil_group_id(classname) 0
+#endif
 
 static MP_INLINE
 int mpxs_Apache2__ServerRec_is_perl_option_enabled(pTHX_ server_rec *s,

Modified: perl/modperl/trunk/xs/maps/modperl_functions.map
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/maps/modperl_functions.map?rev=370270r1=370269r2=370270view=diff
==
--- perl/modperl/trunk/xs/maps/modperl_functions.map (original)
+++ perl/modperl/trunk/xs/maps/modperl_functions.map Wed Jan 18 13:47:36 2006
@@ -87,6 +87,8 @@
 
 MODULE=Apache2::ServerUtil   PACKAGE=Apache2::ServerUtil
  server_rec *:DEFINE_server | | SV *:classname=Nullsv
+ uid_t:DEFINE_user_id   | | SV *:classname=Nullsv
+ gid_t:DEFINE_group_id  | | SV *:classname=Nullsv
 
 MODULE=Apache2::Connection
  mpxs_Apache2__Connection_client_socket | | c, s=NULL




svn commit: r348394 - in /perl/modperl/trunk: Changes src/modules/perl/modperl_io.c

2005-11-22 Thread stas
Author: stas
Date: Tue Nov 22 23:35:34 2005
New Revision: 348394

URL: http://svn.apache.org/viewcvs?rev=348394view=rev
Log:
Perl_do_open/close fixes to make mod_perl 2.0 compile with
[EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_io.c

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=348394r1=348393r2=348394view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Tue Nov 22 23:35:34 2005
@@ -12,6 +12,9 @@
 
 =item 2.0.3-dev
 
+Perl_do_open/close fixes to make mod_perl 2.0 compile with
[EMAIL PROTECTED] (5.9.3+) [Stas]
+
 Added Apache2::PerlSections-server, returning the server
 into which the Perl section is defined [Gozer]
 

Modified: perl/modperl/trunk/src/modules/perl/modperl_io.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_io.c?rev=348394r1=348393r2=348394view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_io.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_io.c Tue Nov 22 23:35:34 2005
@@ -121,8 +121,8 @@
  TRUE, SVt_PVIO);
 
 /* open my $oldout, STDIN or die Can't dup STDIN: $!; */
-status = Perl_do_open(aTHX_ handle_save, STDIN, 7, FALSE,
-  O_RDONLY, 0, Nullfp);
+status = do_open(handle_save, STDIN, 7, FALSE,
+ O_RDONLY, 0, Nullfp);
 if (status == 0) {
 Perl_croak(aTHX_ Failed to dup STDIN: % SVf, get_sv(!, TRUE));
 }
@@ -130,12 +130,12 @@
 /* similar to PerlIO::scalar, the PerlIO::Apache layer doesn't
  * have file descriptors, so STDIN must be closed before it can
  * be reopened */
-Perl_do_close(aTHX_ handle, TRUE);
+do_close(handle, TRUE);
 }
 
 sv_setref_pv(sv, Apache2::RequestRec, (void*)r);
-status = Perl_do_open9(aTHX_ handle, :Apache2, 9, FALSE, O_RDONLY,
-   0, Nullfp, sv, 1);
+status = do_open9(handle, :Apache2, 9, FALSE, O_RDONLY,
+  0, Nullfp, sv, 1);
 if (status == 0) {
 Perl_croak(aTHX_ Failed to open STDIN: % SVf, get_sv(!, TRUE));
 }
@@ -164,8 +164,8 @@
  TRUE, SVt_PVIO);
 
 /* open my $oldout, STDOUT or die Can't dup STDOUT: $!; */
-status = Perl_do_open(aTHX_ handle_save, STDOUT, 8, FALSE,
-  O_WRONLY, 0, Nullfp);
+status = do_open(handle_save, STDOUT, 8, FALSE,
+ O_WRONLY, 0, Nullfp);
 if (status == 0) {
 Perl_croak(aTHX_ Failed to dup STDOUT: % SVf, get_sv(!, TRUE));
 }
@@ -173,12 +173,12 @@
 /* similar to PerlIO::scalar, the PerlIO::Apache layer doesn't
  * have file descriptors, so STDOUT must be closed before it can
  * be reopened */
-Perl_do_close(aTHX_ handle, TRUE);
+do_close(handle, TRUE);
 }
 
 sv_setref_pv(sv, Apache2::RequestRec, (void*)r);
-status = Perl_do_open9(aTHX_ handle, :Apache2, 9, FALSE, O_WRONLY,
-   0, Nullfp, sv, 1);
+status = do_open9(handle, :Apache2, 9, FALSE, O_WRONLY,
+  0, Nullfp, sv, 1);
 if (status == 0) {
 Perl_croak(aTHX_ Failed to open STDOUT: % SVf, get_sv(!, TRUE));
 }
@@ -200,7 +200,7 @@
 MP_TRACE_o(MP_FUNC, start);
 
 /* close the overriding filehandle */
-Perl_do_close(aTHX_ handle_orig, FALSE);
+do_close(handle_orig, FALSE);
 
 /*
  * open STDIN, STDIN_SAVED or die Can't dup STDIN_SAVED: $!;
@@ -211,12 +211,12 @@
 
 MP_TRACE_o(MP_FUNC, restoring STDIN);
 
-if (Perl_do_open9(aTHX_ handle_orig, , 2, FALSE,
-  O_RDONLY, 0, Nullfp, (SV*)handle, 1) == 0) {
+if (do_open9(handle_orig, , 2, FALSE,
+ O_RDONLY, 0, Nullfp, (SV*)handle, 1) == 0) {
 err = get_sv(!, TRUE);
 }
 
-Perl_do_close(aTHX_ handle, FALSE);
+do_close(handle, FALSE);
 (void)hv_delete(gv_stashpv(Apache2::RequestIO, TRUE), 
 GvNAME(handle), GvNAMELEN(handle), G_DISCARD);
 
@@ -247,7 +247,7 @@
 }
 
 /* close the overriding filehandle */
-Perl_do_close(aTHX_ handle_orig, FALSE);
+do_close(handle_orig, FALSE);
 
 /*
  * open STDOUT, STDOUT_SAVED or die Can't dup STDOUT_SAVED: $!;
@@ -258,12 +258,12 @@
 
 MP_TRACE_o(MP_FUNC, restoring STDOUT);
 
-if (Perl_do_open9(aTHX_ handle_orig, , 2, FALSE,
-  O_WRONLY, 0, Nullfp, (SV*)handle, 1) == 0) {
+if (do_open9(handle_orig, , 2, FALSE,
+ O_WRONLY, 0, Nullfp, (SV*)handle, 1) == 0) {
 err = get_sv(!, TRUE

svn commit: r293474 - /perl/modperl/trunk/Makefile.PL

2005-10-03 Thread stas
Author: stas
Date: Mon Oct  3 17:20:13 2005
New Revision: 293474

URL: http://svn.apache.org/viewcvs?rev=293474view=rev
Log:
style

Modified:
perl/modperl/trunk/Makefile.PL

Modified: perl/modperl/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Makefile.PL?rev=293474r1=293473r2=293474view=diff
==
--- perl/modperl/trunk/Makefile.PL (original)
+++ perl/modperl/trunk/Makefile.PL Mon Oct  3 17:20:13 2005
@@ -480,11 +480,11 @@
 
 open my $fh, 'Changes';
 while ($fh) {
-   if (/^=item.*-dev/) {
-   $VERSION .= '-dev';
-   last;
-   }
-   last if /^=item/;
+if (/^=item.*-dev/) {
+$VERSION .= '-dev';
+last;
+}
+last if /^=item/;
 }
 close $fh;
 




svn commit: r293476 - /perl/modperl/trunk/Makefile.PL

2005-10-03 Thread stas
Author: stas
Date: Mon Oct  3 17:30:04 2005
New Revision: 293476

URL: http://svn.apache.org/viewcvs?rev=293476view=rev
Log:
untabify

Modified:
perl/modperl/trunk/Makefile.PL

Modified: perl/modperl/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Makefile.PL?rev=293476r1=293475r2=293476view=diff
==
--- perl/modperl/trunk/Makefile.PL (original)
+++ perl/modperl/trunk/Makefile.PL Mon Oct  3 17:30:04 2005
@@ -89,7 +89,7 @@
 },
 dist  = {
 DIST_DEFAULT = 'mydist',
-   COMPRESS = 'gzip -9f', SUFFIX='gz',
+COMPRESS = 'gzip -9f', SUFFIX='gz',
 },
 );
 
@@ -547,17 +547,17 @@
 
 my $ccflags = $build-perl_config('ccflags');
 for (split /\s+/, $ccflags) {
-   next unless s/^-I//;
-   my $header = $_/ap_mmn.h;
-   if (-e $header) {
-   $build-phat_warn(EOF);
+next unless s/^-I//;
+my $header = $_/ap_mmn.h;
+if (-e $header) {
+$build-phat_warn(EOF);
 Apache headers found in unexpected location: ``$_'', suggestions:
*) Remove via ``rpm -e apache''
*) Remove by hand
*) Complain to your os vendor about their poor layout choice
*) Complain to your sysadmin about their poor layout choice
 EOF
-   }
+}
 }
 
 $build-lib_check('gdbm');




svn commit: r291801 - /perl/modperl/trunk/t/lib/TestCommon/LogDiff.pm

2005-09-26 Thread stas
Author: stas
Date: Mon Sep 26 17:41:42 2005
New Revision: 291801

URL: http://svn.apache.org/viewcvs?rev=291801view=rev
Log:
add strict, fix bug

Modified:
perl/modperl/trunk/t/lib/TestCommon/LogDiff.pm

Modified: perl/modperl/trunk/t/lib/TestCommon/LogDiff.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/lib/TestCommon/LogDiff.pm?rev=291801r1=291800r2=291801view=diff
==
--- perl/modperl/trunk/t/lib/TestCommon/LogDiff.pm (original)
+++ perl/modperl/trunk/t/lib/TestCommon/LogDiff.pm Mon Sep 26 17:41:42 2005
@@ -1,5 +1,8 @@
 package TestCommon::LogDiff;
 
+use strict;
+use warnings FATAL = 'all';
+
 use POSIX ();
 
 sub new {
@@ -8,7 +11,7 @@
 
 open my $fh, $path or die Can't open $path: $!;
 seek $fh, 0, POSIX::SEEK_END();
-$pos = tell $fh;
+my $pos = tell $fh;
 
 my %self = (
 path = $path,




svn commit: r291058 - /perl/modperl/branches/apache2-rename-unstable/

2005-09-22 Thread stas
Author: stas
Date: Thu Sep 22 19:07:52 2005
New Revision: 291058

URL: http://svn.apache.org/viewcvs?rev=291058view=rev
Log:
Merged successfully to trunk/

Removed:
perl/modperl/branches/apache2-rename-unstable/



svn commit: r290331 - /perl/modperl/trunk/lib/Apache2/PerlSections/Dump.pm

2005-09-19 Thread stas
Author: stas
Date: Mon Sep 19 19:18:54 2005
New Revision: 290331

URL: http://svn.apache.org/viewcvs?rev=290331view=rev
Log:
tidy up

Modified:
perl/modperl/trunk/lib/Apache2/PerlSections/Dump.pm

Modified: perl/modperl/trunk/lib/Apache2/PerlSections/Dump.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/PerlSections/Dump.pm?rev=290331r1=290330r2=290331view=diff
==
--- perl/modperl/trunk/lib/Apache2/PerlSections/Dump.pm (original)
+++ perl/modperl/trunk/lib/Apache2/PerlSections/Dump.pm Mon Sep 19 19:18:54 2005
@@ -61,17 +61,18 @@
 sub dump_hash {
 my ($self, $name, $entry) = @_;
 for my $elem (sort keys %{$entry}) {
-$self-add_config(Data::Dumper-Dump([$entry-{$elem}], 
[\$$name.{'$elem'}])); 
+$self-add_config(Data::Dumper-Dump([$entry-{$elem}],
+ [\$$name.{'$elem'}]));
 }
-
+
 }
 
 sub dump_entry {
 my ($self, $name, $entry) = @_;
-
+
 return if not defined $entry;
 my $type = ref($entry);
-
+
 if ($type eq 'SCALAR') {
 $self-add_config(Data::Dumper-Dump([$$entry],[$name]));
 }
@@ -85,7 +86,7 @@
 
 sub dump_special {
 my ($self, @data) = @_;
-
+
 my @dump = grep { defined } @data;
 return unless @dump;
 




svn commit: r267275 - /perl/modperl/trunk/lib/Apache2/Build.pm

2005-09-02 Thread stas
Author: stas
Date: Fri Sep  2 12:09:13 2005
New Revision: 267275

URL: http://svn.apache.org/viewcvs?rev=267275view=rev
Log:
- remove whitespace
- wrap long lines

Modified:
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=267275r1=267274r2=267275view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Fri Sep  2 12:09:13 2005
@@ -310,21 +310,23 @@
 
 my $mplibpath = '';
 my $ldopts = $self-ldopts;
-
+
 if (CYGWIN) {
-# Cygwin's httpd port links its modules into httpd2core.dll, instead 
of httpd.exe.
-# In this case, we have a problem, because libtool doesn't want to 
include
-# static libs (.a) into a dynamic lib (.dll). Workaround this by 
setting
-# mod_perl.a as a linker argument (including all other flags and libs).
+# Cygwin's httpd port links its modules into httpd2core.dll,
+# instead of httpd.exe. In this case, we have a problem,
+# because libtool doesn't want to include static libs (.a)
+# into a dynamic lib (.dll). Workaround this by setting
+# mod_perl.a as a linker argument (including all other flags
+# and libs).
 my $mplib  = $self-{MP_LIBNAME}$Config{lib_ext};
-
-$ldopts = join ' ', 
+
+$ldopts = join ' ',
 '--export-all-symbols',
 $self-{cwd}/src/modules/perl/$mplib,
 $ldopts;
-
+
 $ldopts =~ s/(\S+)/-Wl,$1/g;
-
+
 } else {
 my $mplib  = $self-{MP_LIBNAME}$Config{lib_ext};
 $mplibpath = catfile($self-{cwd}, qw(src modules perl), $mplib);
@@ -334,13 +336,13 @@
 local $ENV{AP_LIBS} = $ldopts;
 local $ENV{MODLIST} = 'perl';
 
-#XXX: -Wall and/or -Werror at httpd configure time breaks things
+# XXX: -Wall and/or -Werror at httpd configure time breaks things
 local $ENV{CFLAGS} = join ' ', grep { ! /\-Wall|\-Werror/ } 
 split /\s+/, $ENV{CFLAGS} || '';
 
 my $cd = qq(cd $self-{MP_AP_PREFIX});
 
-#We need to clean the httpd tree before configuring it
+# We need to clean the httpd tree before configuring it
 if (-f File::Spec-catfile($self-{MP_AP_PREFIX}, 'Makefile')) {
 my $cmd = qq(make clean);
 debug Running $cmd;
@@ -1609,11 +1611,11 @@
 my $apache_corelib_cygwin;
 sub apache_corelib_cygwin {
 return $apache_corelib_cygwin if $apache_corelib_cygwin;
-
+
 my $self = shift;
 my $mp_src = $self-{cwd}/src/modules/perl;
 my $core = 'httpd2core';
-
+
 # There's a problem with user-installed perl on cygwin.
 # MakeMaker doesn't know about the .dll.a libs and warns
 # about missing -lhttpd2core. Fix it by copying
@@ -1629,7 +1631,7 @@
 qx{touch $libpath/lib$core.dll.a  \
 ln -fs $libpath/lib$core.dll.a $mp_src/lib$core.a};
 }
-
+
 $apache_corelib_cygwin = -L$mp_src -l$core;
 }
 




svn commit: r267276 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm

2005-09-02 Thread stas
Author: stas
Date: Fri Sep  2 12:11:43 2005
New Revision: 267276

URL: http://svn.apache.org/viewcvs?rev=267276view=rev
Log:
On cygwin some dlls might happen to be with identical base addresses
and if you try to load both of them you'll get an error and you'll
have to use the rebase utility to fix them.  this fix should prevent
this. 
Submitted by: Nikolay Ananiev [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=267276r1=267275r2=267276view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri Sep  2 12:11:43 2005
@@ -12,6 +12,11 @@
 
 =item 2.0.2-dev
 
+On cygwin some dlls might happen to be with identical base addresses
+and if you try to load both of them you'll get an error and you'll
+have to use the rebase utility to fix them.  this fix should prevent
+this.  [Nikolay Ananiev [EMAIL PROTECTED]]
+
 Fix an undefined warning in DSO builds when not using MP_APXS.
 [Nikolay Ananiev [EMAIL PROTECTED]]
 

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=267276r1=267275r2=267276view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Fri Sep  2 12:11:43 2005
@@ -322,6 +322,7 @@
 
 $ldopts = join ' ',
 '--export-all-symbols',
+'--enable-auto-image-base',
 $self-{cwd}/src/modules/perl/$mplib,
 $ldopts;
 
@@ -1592,7 +1593,8 @@
$(MODPERL_RM_F) $@
$(MODPERL_CC) -shared -o $@ \
-Wl,--out-implib=$(MODPERL_LIBNAME).dll.a \
-   -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--stack,8388608 \
+   -Wl,--export-all-symbols -Wl,--enable-auto-import \
+   -Wl,--enable-auto-image-base -Wl,--stack,8388608 \
$(MODPERL_PIC_OBJS) \
$(MODPERL_LDDLFLAGS) $(MODPERL_LDOPTS) \
$(MODPERL_AP_LIBS)




svn commit: r264897 - /perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm

2005-08-30 Thread stas
Author: stas
Date: Tue Aug 30 17:01:47 2005
New Revision: 264897

URL: http://svn.apache.org/viewcvs?rev=264897view=rev
Log:
missing constant

Modified:
perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm

Modified: perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm?rev=264897r1=264896r2=264897view=diff
==
--- perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm (original)
+++ perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm Tue Aug 30 17:01:47 2005
@@ -9,6 +9,7 @@
 require Chatbot::Eliza;
 
 use Apache2::Const -compile = 'OK';
+use APR::Const -compile = 'SO_NONBLOCK';
 
 use constant BUFF_LEN = 1024;
 




svn commit: r233275 - in /perl/modperl/trunk: Changes src/modules/perl/modperl_filter.c t/filter/TestFilter/in_str_declined_read.pm t/filter/in_str_declined_read.t

2005-08-17 Thread stas
Author: stas
Date: Wed Aug 17 17:37:06 2005
New Revision: 233275

URL: http://svn.apache.org/viewcvs?rev=233275view=rev
Log:
croak in case a filter returns DECLINED after calling $f-read (as it
is not supposed to happen)

Added:
perl/modperl/trunk/t/filter/TestFilter/in_str_declined_read.pm   (with 
props)
perl/modperl/trunk/t/filter/in_str_declined_read.t   (with props)
Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_filter.c

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=233275r1=233274r2=233275view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed Aug 17 17:37:06 2005
@@ -12,6 +12,9 @@
 
 =item 2.0.2-dev
 
+croak in case a filter returns DECLINED after calling $f-read (as it
+is not supposed to happen) [Stas]
+
 another round of cygwin fixes [Nick *** [EMAIL PROTECTED]]
 
 Multiple fixes to make mod_perl 2.0 work with blead-perl (5.9.3+)

Modified: perl/modperl/trunk/src/modules/perl/modperl_filter.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_filter.c?rev=233275r1=233274r2=233275view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_filter.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_filter.c Wed Aug 17 17:37:06 
2005
@@ -544,6 +544,15 @@
 
 if (filter-mode == MP_INPUT_FILTER_MODE) {
 if (filter-bb_in) {
+if (status == DECLINED) {
+/* make sure the filter doesn't try to make mod_perl
+ * pass the bucket brigade through after it called
+ * $f-read(), since it causes a pre-fetch of the
+ * bb */
+modperl_croak(aTHX_ MODPERL_FILTER_ERROR,
+  a filter calling $f-read 
+  must return OK and not DECLINED);
+}
 /* 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

Added: perl/modperl/trunk/t/filter/TestFilter/in_str_declined_read.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/TestFilter/in_str_declined_read.pm?rev=233275view=auto
==
--- perl/modperl/trunk/t/filter/TestFilter/in_str_declined_read.pm (added)
+++ perl/modperl/trunk/t/filter/TestFilter/in_str_declined_read.pm Wed Aug 17 
17:37:06 2005
@@ -0,0 +1,51 @@
+package TestFilter::in_str_declined_read;
+
+use strict;
+use warnings FATAL = 'all';
+
+use Apache::Test;
+use Apache::TestUtil;
+
+use Apache2::RequestRec ();
+use Apache2::RequestIO ();
+
+use Apache2::Filter ();
+
+use TestCommon::Utils ();
+
+use Apache2::Const -compile = qw(OK DECLINED M_POST);
+
+# a filter must not return DECLINED after calling $r-read, since the
+# latter already fetches the bucket brigade in which case it's up to
+# the user to complete reading it and send it out
+# thefore this filter must fail
+sub handler {
+  my $filter = shift;
+
+  # this causes a fetch of bb
+  $filter-read(my $buffer, 10);
+
+  return Apache2::Const::DECLINED;
+}
+
+sub response {
+my $r = shift;
+
+plan $r, tests = 1;
+
+$r-content_type('text/plain');
+
+if ($r-method_number == Apache2::Const::M_POST) {
+# this should fail, because of the failing filter
+eval { TestCommon::Utils::read_post($r) };
+ok $@;
+}
+
+Apache2::Const::OK;
+}
+1;
+__DATA__
+SetHandler modperl
+PerlModule  TestFilter::in_str_declined_read
+PerlResponseHandler TestFilter::in_str_declined_read::response
+

Propchange: perl/modperl/trunk/t/filter/TestFilter/in_str_declined_read.pm
--
svn:eol-style = native

Added: perl/modperl/trunk/t/filter/in_str_declined_read.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/in_str_declined_read.t?rev=233275view=auto
==
--- perl/modperl/trunk/t/filter/in_str_declined_read.t (added)
+++ perl/modperl/trunk/t/filter/in_str_declined_read.t Wed Aug 17 17:37:06 2005
@@ -0,0 +1,11 @@
+use strict;
+use warnings FATAL = 'all';
+
+use Apache::TestRequest 'POST_BODY_ASSERT';;
+
+my $location = '/TestFilter__in_str_declined_read';
+
+my $chunk = 1234567890;
+my $data = $chunk x 2000;
+
+print POST_BODY_ASSERT $location, content = $data;

Propchange: perl/modperl/trunk/t/filter/in_str_declined_read.t
--
svn:eol-style = native




svn commit: r233075 - /perl/modperl/trunk/t/response/TestAPI/access2.pm

2005-08-16 Thread stas
Author: stas
Date: Tue Aug 16 16:03:56 2005
New Revision: 233075

URL: http://svn.apache.org/viewcvs?rev=233075view=rev
Log:
adjust the test not to rely on @servername@ which for some reason mismatches on 
the 
some setups (making mod_auth fail). so instead use the 'allow from all' test, 
which 
should be still good enough for $r-satisfies test

Modified:
perl/modperl/trunk/t/response/TestAPI/access2.pm

Modified: perl/modperl/trunk/t/response/TestAPI/access2.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestAPI/access2.pm?rev=233075r1=233074r2=233075view=diff
==
--- perl/modperl/trunk/t/response/TestAPI/access2.pm (original)
+++ perl/modperl/trunk/t/response/TestAPI/access2.pm Tue Aug 16 16:03:56 2005
@@ -98,9 +98,7 @@
 
 IfModule @ACCESS_MODULE@
 # needed to test $r-satisfies
-Order Deny,Allow
-Deny from all
-Allow from @servername@
+Allow from All
 /IfModule
 AuthType Basic
 AuthName Access




svn commit: r231356 - in /perl/modperl/trunk/ModPerl-Registry/t: 206.t 304.t 404.t cgi.t closure.t flush.t perlrun_extload.t redirect.t special_blocks.t

2005-08-10 Thread stas
Author: stas
Date: Wed Aug 10 16:56:57 2005
New Revision: 231356

URL: http://svn.apache.org/viewcvs?rev=231356view=rev
Log:
skip tests if HTML::HeadParser is not available

Modified:
perl/modperl/trunk/ModPerl-Registry/t/206.t
perl/modperl/trunk/ModPerl-Registry/t/304.t
perl/modperl/trunk/ModPerl-Registry/t/404.t
perl/modperl/trunk/ModPerl-Registry/t/cgi.t
perl/modperl/trunk/ModPerl-Registry/t/closure.t
perl/modperl/trunk/ModPerl-Registry/t/flush.t
perl/modperl/trunk/ModPerl-Registry/t/perlrun_extload.t
perl/modperl/trunk/ModPerl-Registry/t/redirect.t
perl/modperl/trunk/ModPerl-Registry/t/special_blocks.t

Modified: perl/modperl/trunk/ModPerl-Registry/t/206.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/206.t?rev=231356r1=231355r2=231356view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/206.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/206.t Wed Aug 10 16:56:57 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests = 2, need 'mod_alias.c';
+plan tests = 2, need [qw(mod_alias.c HTML::HeadParser)];
 
 my $url = /registry/206.pl;
 my $res = GET($url);

Modified: perl/modperl/trunk/ModPerl-Registry/t/304.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/304.t?rev=231356r1=231355r2=231356view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/304.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/304.t Wed Aug 10 16:56:57 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests = 10, need 'mod_alias.c';
+plan tests = 10, need [qw(mod_alias.c HTML::HeadParser)];
 
 my $url = /registry/304.pl;
 

Modified: perl/modperl/trunk/ModPerl-Registry/t/404.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/404.t?rev=231356r1=231355r2=231356view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/404.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/404.t Wed Aug 10 16:56:57 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET_BODY GET);
 
-plan tests = 2, need 'mod_alias.c';
+plan tests = 2, need [qw(mod_alias.c HTML::HeadParser)];
 
 {
 t_client_log_error_is_expected();

Modified: perl/modperl/trunk/ModPerl-Registry/t/cgi.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/cgi.t?rev=231356r1=231355r2=231356view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/cgi.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/cgi.t Wed Aug 10 16:56:57 2005
@@ -5,7 +5,8 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests = 2, need 'mod_alias.c', need_min_module_version CGI = 3.08;
+plan tests = 2, need [qw(mod_alias.c HTML::HeadParser)],
+need_min_module_version CGI = 3.08;
 
 my $url = /registry/cgi.pl;
 my $res = GET $url;

Modified: perl/modperl/trunk/ModPerl-Registry/t/closure.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/closure.t?rev=231356r1=231355r2=231356view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/closure.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/closure.t Wed Aug 10 16:56:57 2005
@@ -17,7 +17,7 @@
 
 my @modules = qw(registry registry_bb perlrun);
 
-plan tests = 6, need 'mod_alias.c';
+plan tests = 6, need [qw(mod_alias.c HTML::HeadParser)];
 
 my $cfg = Apache::Test::config();
 

Modified: perl/modperl/trunk/ModPerl-Registry/t/flush.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/flush.t?rev=231356r1=231355r2=231356view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/flush.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/flush.t Wed Aug 10 16:56:57 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET_BODY);
 
-plan tests = 1, need 'deflate', 'mod_alias.c',
+plan tests = 1, need [qw(mod_alias.c deflate HTML::HeadParser)],
 need_min_module_version(Compress::Zlib, 1.09),
 need_min_apache_version(2.0.48);
 # it requires httpd 2.0.48 because of the bug in mod_deflate:

Modified: perl/modperl/trunk/ModPerl-Registry/t/perlrun_extload.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/perlrun_extload.t?rev=231356r1=231355r2=231356view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/perlrun_extload.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/perlrun_extload.t Wed Aug 10 16:56:57 
2005
@@ -6,7 +6,7 @@
 use Apache::TestRequest qw(GET);
 use TestCommon::SameInterp

svn commit: r219899 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm lib/ModPerl/BuildMM.pm t/filter/out_str_subreq_default.t xs/APR/APR/Makefile.PL

2005-07-20 Thread stas
Author: stas
Date: Wed Jul 20 06:38:16 2005
New Revision: 219899

URL: http://svn.apache.org/viewcvs?rev=219899view=rev
Log:
another round of cygwin fixes
Submitted by Nick *** [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Build.pm
perl/modperl/trunk/lib/ModPerl/BuildMM.pm
perl/modperl/trunk/t/filter/out_str_subreq_default.t
perl/modperl/trunk/xs/APR/APR/Makefile.PL

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=219899r1=219898r2=219899view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed Jul 20 06:38:16 2005
@@ -12,6 +12,8 @@
 
 =item 2.0.2-dev
 
+another round of cygwin fixes [Nick *** [EMAIL PROTECTED]]
+
 Multiple fixes to make mod_perl 2.0 work with blead-perl (5.9.3+)
 [Stas]
 

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=219899r1=219898r2=219899view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Wed Jul 20 06:38:16 2005
@@ -308,11 +308,30 @@
 $self-{'httpd'} ||= $httpd;
 push @Apache::TestMM::Argv, ('httpd' = $self-{'httpd'});
 
-my $mplib = $self-{MP_LIBNAME}$Config{lib_ext};
-my $mplibpath = catfile($self-{cwd}, qw(src modules perl), $mplib);
+my $mplibpath = '';
+my $ldopts = $self-ldopts;
+
+if (CYGWIN) {
+# Cygwin's httpd port links its modules into httpd2core.dll, instead 
of httpd.exe.
+# In this case, we have a problem, because libtool doesn't want to 
include
+# static libs (.a) into a dynamic lib (.dll). Workaround this by 
setting
+# mod_perl.a as a linker argument (including all other flags and libs).
+my $mplib  = $self-{MP_LIBNAME}$Config{lib_ext};
+
+$ldopts = join ' ', 
+'--export-all-symbols',
+$self-{cwd}/src/modules/perl/$mplib,
+$ldopts;
+
+$ldopts =~ s/(\S+)/-Wl,$1/g;
+
+} else {
+my $mplib  = $self-{MP_LIBNAME}$Config{lib_ext};
+$mplibpath = catfile($self-{cwd}, qw(src modules perl), $mplib);
+}
 
 local $ENV{BUILTIN_LIBS} = $mplibpath;
-local $ENV{AP_LIBS} = $self-ldopts;
+local $ENV{AP_LIBS} = $ldopts;
 local $ENV{MODLIST} = 'perl';
 
 #XXX: -Wall and/or -Werror at httpd configure time breaks things
@@ -469,10 +488,6 @@
 $ldopts .= $self-gtop_ldopts;
 }
 
-if (CYGWIN  $self-is_dynamic) {
-$ldopts .= join ' ', '', $self-apru_link_flags;
-}
-
 $config-{ldflags} = $ldflags; #reset
 
 # on Irix mod_perl.so needs to see the libperl.so symbols, which
@@ -802,7 +817,7 @@
 }
 
 return bless {}, (ref($self) || $self) if $@;
-return Apache2::BuildConfig::-new;
+return Apache2::BuildConfig-new;
 }
 
 sub new {
@@ -1122,7 +1137,7 @@
 if ($self-{MP_AP_CONFIGURE} 
 $self-{MP_AP_CONFIGURE} =~ /--with-${what_long}=(\S+)/) {
 my $dir = $1;
-$dir =~ s/$config$// unless -d $dir;
+$dir = dirname $dir if -f $dir;
 push @tries, grep -d $_, $dir, catdir $dir, 'bin';
 }
 }
@@ -1537,6 +1552,21 @@
 \t . '$(MODPERL_RANLIB) $@';
 }
 
+sub dynamic_link_cygwin {
+my $self = shift;
+return 'EOF';
+$(MODPERL_LIBNAME).$(MODPERL_DLEXT): $(MODPERL_PIC_OBJS)
+   $(MODPERL_RM_F) $@
+   $(MODPERL_CC) -shared -o $@ \
+   -Wl,--out-implib=$(MODPERL_LIBNAME).dll.a \
+   -Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--stack,8388608 \
+   $(MODPERL_PIC_OBJS) \
+   $(MODPERL_LDDLFLAGS) $(MODPERL_LDOPTS) \
+   $(MODPERL_AP_LIBS)
+   $(MODPERL_RANLIB) $@
+EOF
+}
+
 sub dynamic_link {
 my $self = shift;
 my $link = \{dynamic_link_$^O};
@@ -1544,6 +1574,34 @@
 $link-($self);
 }
 
+# Returns the link flags for the apache shared core library
+my $apache_corelib_cygwin;
+sub apache_corelib_cygwin {
+return $apache_corelib_cygwin if $apache_corelib_cygwin;
+
+my $self = shift;
+my $mp_src = $self-{cwd}/src/modules/perl;
+my $core = 'httpd2core';
+
+# There's a problem with user-installed perl on cygwin.
+# MakeMaker doesn't know about the .dll.a libs and warns
+# about missing -lhttpd2core. Fix it by copying
+# the lib and adding .a suffix.
+# For the static build create a soft link, because libhttpd2core.dll.a
+# doesn't exist at this time.
+if ($self-is_dynamic) {
+my $libpath = $self-apxs(-q = 'exp_libdir');
+File::Copy::copy($libpath/lib$core.dll.a, $mp_src/lib$core.a);
+} else {
+my $libpath = catdir($self-{MP_AP_PREFIX}, '.libs');
+mkdir $libpath unless -d $libpath

svn commit: r209855 - /perl/modperl/trunk/src/modules/perl/modperl_common_util.c

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:04:13 2005
New Revision: 209855

URL: http://svn.apache.org/viewcvs?rev=209855view=rev
Log:
fix the magic type logging

Modified:
perl/modperl/trunk/src/modules/perl/modperl_common_util.c

Modified: perl/modperl/trunk/src/modules/perl/modperl_common_util.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_common_util.c?rev=209855r1=209854r2=209855view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_common_util.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_common_util.c Fri Jul  8 
12:04:13 2005
@@ -95,7 +95,7 @@
 return mg-mg_obj;
 }
 else {
-Perl_warn(aTHX_ Not a tied hash: (magic=%c), mg);
+Perl_warn(aTHX_ Not a tied hash: (magic=%c), 
mg-mg_type);
 }
 }
 else {




svn commit: r209856 - /perl/modperl/trunk/src/modules/perl/modperl_io.c

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:05:01 2005
New Revision: 209856

URL: http://svn.apache.org/viewcvs?rev=209856view=rev
Log:
blead fix: %_ = % SVf

Modified:
perl/modperl/trunk/src/modules/perl/modperl_io.c

Modified: perl/modperl/trunk/src/modules/perl/modperl_io.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_io.c?rev=209856r1=209855r2=209856view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_io.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_io.c Fri Jul  8 12:05:01 2005
@@ -124,7 +124,7 @@
 status = Perl_do_open(aTHX_ handle_save, STDIN, 7, FALSE,
   O_RDONLY, 0, Nullfp);
 if (status == 0) {
-Perl_croak(aTHX_ Failed to dup STDIN: %_, get_sv(!, TRUE));
+Perl_croak(aTHX_ Failed to dup STDIN: % SVf, get_sv(!, TRUE));
 }
 
 /* similar to PerlIO::scalar, the PerlIO::Apache layer doesn't
@@ -137,7 +137,7 @@
 status = Perl_do_open9(aTHX_ handle, :Apache2, 9, FALSE, O_RDONLY,
0, Nullfp, sv, 1);
 if (status == 0) {
-Perl_croak(aTHX_ Failed to open STDIN: %_, get_sv(!, TRUE));
+Perl_croak(aTHX_ Failed to open STDIN: % SVf, get_sv(!, TRUE));
 }
 
 MP_TRACE_o(MP_FUNC, end\n);
@@ -167,7 +167,7 @@
 status = Perl_do_open(aTHX_ handle_save, STDOUT, 8, FALSE,
   O_WRONLY, 0, Nullfp);
 if (status == 0) {
-Perl_croak(aTHX_ Failed to dup STDOUT: %_, get_sv(!, TRUE));
+Perl_croak(aTHX_ Failed to dup STDOUT: % SVf, get_sv(!, TRUE));
 }
 
 /* similar to PerlIO::scalar, the PerlIO::Apache layer doesn't
@@ -180,7 +180,7 @@
 status = Perl_do_open9(aTHX_ handle, :Apache2, 9, FALSE, O_WRONLY,
0, Nullfp, sv, 1);
 if (status == 0) {
-Perl_croak(aTHX_ Failed to open STDOUT: %_, get_sv(!, TRUE));
+Perl_croak(aTHX_ Failed to open STDOUT: % SVf, get_sv(!, TRUE));
 }
 
 MP_TRACE_o(MP_FUNC, end\n);
@@ -221,7 +221,7 @@
 GvNAME(handle), GvNAMELEN(handle), G_DISCARD);
 
 if (err != Nullsv) {
-Perl_croak(aTHX_ Failed to restore STDIN: %_, err);
+Perl_croak(aTHX_ Failed to restore STDIN: % SVf, err);
 }
 }
 
@@ -243,7 +243,7 @@
  */
 if (GvIOn(handle_orig)  IoOFP(GvIOn(handle_orig)) 
 (PerlIO_flush(IoOFP(GvIOn(handle_orig))) == -1)) {
-Perl_croak(aTHX_ Failed to flush STDOUT: %_, get_sv(!, TRUE));
+Perl_croak(aTHX_ Failed to flush STDOUT: % SVf, get_sv(!, TRUE));
 }
 
 /* close the overriding filehandle */
@@ -268,7 +268,7 @@
 GvNAME(handle), GvNAMELEN(handle), G_DISCARD);
 
 if (err != Nullsv) {
-Perl_croak(aTHX_ Failed to restore STDOUT: %_, err);
+Perl_croak(aTHX_ Failed to restore STDOUT: % SVf, err);
 }
 }
 




svn commit: r209857 - /perl/modperl/trunk/src/modules/perl/mod_perl.c

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:05:32 2005
New Revision: 209857

URL: http://svn.apache.org/viewcvs?rev=209857view=rev
Log:
perl blead fix: %vd doesn't work anymore

Modified:
perl/modperl/trunk/src/modules/perl/mod_perl.c

Modified: perl/modperl/trunk/src/modules/perl/mod_perl.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/mod_perl.c?rev=209857r1=209856r2=209857view=diff
==
--- perl/modperl/trunk/src/modules/perl/mod_perl.c (original)
+++ perl/modperl/trunk/src/modules/perl/mod_perl.c Fri Jul  8 12:05:32 2005
@@ -695,9 +695,17 @@
 }
 #endif
 
+#if PERL_REVISION == 5  PERL_VERSION  9
+#define MP_PERL_VERSION_STAMP Perl/v%vd
+#else
+#define MP_PERL_VERSION_STAMP Perl/% SVf
+#endif
+
 ap_add_version_component(pconf, MP_VERSION_STRING);
 ap_add_version_component(pconf,
- Perl_form(aTHX_ Perl/v%vd, PL_patchlevel));
+ Perl_form(aTHX_ MP_PERL_VERSION_STAMP,
+   PL_patchlevel));
+
 modperl_mgv_hash_handlers(pconf, s);
 modperl_modglobal_hash_keys(aTHX);
 modperl_env_hash_keys(aTHX);




svn commit: r209858 - /perl/modperl/trunk/src/modules/perl/modperl_mgv.c

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:06:22 2005
New Revision: 209858

URL: http://svn.apache.org/viewcvs?rev=209858view=rev
Log:
perl blead fix: HvNAME() may return 0 (fixing a warning for a potential 
strlen(0))

Modified:
perl/modperl/trunk/src/modules/perl/modperl_mgv.c

Modified: perl/modperl/trunk/src/modules/perl/modperl_mgv.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_mgv.c?rev=209858r1=209857r2=209858view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_mgv.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_mgv.c Fri Jul  8 12:06:22 2005
@@ -320,8 +320,17 @@
 MpHandlerMETHOD_On(handler);
 }
 
+if (!stash) {
+return 0;
+}
+
+
 if (MpHandlerMETHOD(handler)  !handler-mgv_obj) {
-modperl_mgv_new_name(handler-mgv_obj, p, HvNAME(stash));
+char *name = HvNAME(stash);
+if (!name) {
+name = ;
+}
+modperl_mgv_new_name(handler-mgv_obj, p, name);
 }
 
 handler-attrs = (U32)MP_CODE_ATTRS(cv);




svn commit: r209859 - /perl/modperl/trunk/src/modules/perl/modperl_interp.h

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:07:46 2005
New Revision: 209859

URL: http://svn.apache.org/viewcvs?rev=209859view=rev
Log:
perl blead fix: in 5.9.3 HvPMROOT was completely removed, temporary using 
Perl_Imodglobal_ptr(thx)))-xmg_magic (which fails on perl_clone from ithreads, 
but 
otherwise works). this must be replaced with a better solution once we find it.

Modified:
perl/modperl/trunk/src/modules/perl/modperl_interp.h

Modified: perl/modperl/trunk/src/modules/perl/modperl_interp.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_interp.h?rev=209859r1=209858r2=209859view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_interp.h (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_interp.h Fri Jul  8 12:07:46 
2005
@@ -27,12 +27,28 @@
  * HvPMROOT will never be used by Perl with PL_modglobal.
  * so we have stolen it as a quick way to stash the interp
  * pointer.
+ *
+ * However in 5.9.3 HvPMROOT was completely removed, so we have moved
+ * to use another struct member that's hopefully won't be used by
+ * anybody else. But if we can find a better place to store the
+ * pointer to the current mod_perl interpreter object it'd be a much
+ * cleaner solution. of course it must be really fast.
  */
+#ifndef HvPMROOT
+#define MP_THX_INTERP_GET(thx)  \
+(modperl_interp_t *) ((XPVMG*)SvANY(*Perl_Imodglobal_ptr(thx)))-xmg_magic
+#else
 #define MP_THX_INTERP_GET(thx) \
 (modperl_interp_t *)HvPMROOT(*Perl_Imodglobal_ptr(thx))
+#endif
 
-#define MP_THX_INTERP_SET(thx, interp) \
+#ifndef HvPMROOT
+#define MP_THX_INTERP_SET(thx, interp)  \
+((XPVMG*)SvANY(*Perl_Imodglobal_ptr(thx)))-xmg_magic = (MAGIC*)interp
+#else
+#define MP_THX_INTERP_SET(thx, interp)  \
 HvPMROOT(*Perl_Imodglobal_ptr(thx)) = (PMOP*)interp
+#endif
 
 const char *modperl_interp_scope_desc(modperl_interp_scope_e scope);
 




svn commit: r209860 - /perl/modperl/trunk/src/modules/perl/modperl_util.c

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:08:53 2005
New Revision: 209860

URL: http://svn.apache.org/viewcvs?rev=209860view=rev
Log:
perl blead fixes:
- xhv-xhv_array doesn't exist anymore, using the wrapper HvARRAY(hv)
- types casting

Modified:
perl/modperl/trunk/src/modules/perl/modperl_util.c

Modified: perl/modperl/trunk/src/modules/perl/modperl_util.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_util.c?rev=209860r1=209859r2=209860view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_util.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_util.c Fri Jul  8 12:08:53 2005
@@ -136,7 +136,7 @@
 break;
   default:
 Perl_croak(aTHX_ panic: unsupported request_rec type %d,
-   SvTYPE(rv));
+   (int)SvTYPE(rv));
 }
 }
 
@@ -408,7 +408,7 @@
 register HE *entry;
 
 xhv = (XPVHV *)SvANY(hv);
-if (!xhv-xhv_array) {
+if (!HvARRAY(hv)) {
 return 0;
 }
 
@@ -422,7 +422,7 @@
PERL_HASH(hash, key, klen);
 }
 
-entry = ((HE**)xhv-xhv_array)[hash  (I32)xhv-xhv_max];
+entry = ((HE**)HvARRAY(hv))[hash  (I32)xhv-xhv_max];
 
 for (; entry; entry = HeNEXT(entry)) {
 if (HeHASH(entry) != hash) {
@@ -633,7 +633,7 @@
 if (r-finfo.size != size) {
 SvREFCNT_dec(sv); 
 Perl_croak(aTHX_ Error: read %d bytes, expected %d ('%s'),
-   size, r-finfo.size, r-filename);
+   size, (apr_size_t)r-finfo.size, r-filename);
 }
 
 rc = apr_file_close(file);




svn commit: r209861 - /perl/modperl/trunk/src/modules/perl/modperl_cmd.c

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:09:49 2005
New Revision: 209861

URL: http://svn.apache.org/viewcvs?rev=209861view=rev
Log:
blead perl temp fix: some recent change introduced tainting problems, will 
remove 
the workaround once blead perl is fixed

Modified:
perl/modperl/trunk/src/modules/perl/modperl_cmd.c

Modified: perl/modperl/trunk/src/modules/perl/modperl_cmd.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_cmd.c?rev=209861r1=209860r2=209861view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_cmd.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_cmd.c Fri Jul  8 12:09:49 2005
@@ -554,6 +554,9 @@
 GV *gv = gv_fetchpv(0, TRUE, SVt_PV);
 ENTER;SAVETMPS;
 save_scalar(gv); /* local $0 */
+#if PERL_REVISION == 5  PERL_VERSION = 9
+TAINT_NOT; /* XXX: temp workaround, see my p5p post */
+#endif
 sv_setpv_mg(GvSV(gv), directive-filename);
 eval_sv(code, G_SCALAR|G_KEEPERR);
 SvREFCNT_dec(code);




svn commit: r209862 - /perl/modperl/trunk/xs/ModPerl/Util/ModPerl__Util.h

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:10:18 2005
New Revision: 209862

URL: http://svn.apache.org/viewcvs?rev=209862view=rev
Log:
blead perl fix: casting warning

Modified:
perl/modperl/trunk/xs/ModPerl/Util/ModPerl__Util.h

Modified: perl/modperl/trunk/xs/ModPerl/Util/ModPerl__Util.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/ModPerl/Util/ModPerl__Util.h?rev=209862r1=209861r2=209862view=diff
==
--- perl/modperl/trunk/xs/ModPerl/Util/ModPerl__Util.h (original)
+++ perl/modperl/trunk/xs/ModPerl/Util/ModPerl__Util.h Fri Jul  8 12:10:18 2005
@@ -18,7 +18,7 @@
 Perl_newSVpvf(aTHX_ 0x%lx, (unsigned long)aTHX)
 #else
 #define mpxs_ModPerl__Util_current_perl_id() \
-Perl_newSVpvf(aTHX_ 0x%lx, 0)
+Perl_newSVpvf(aTHX_ 0x%lx, (unsigned long)0)
 #endif
 
 static MP_INLINE void mpxs_ModPerl__Util_untaint(pTHX_ I32 items,




svn commit: r209864 - /perl/modperl/trunk/Changes

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:14:59 2005
New Revision: 209864

URL: http://svn.apache.org/viewcvs?rev=209864view=rev
Log:
recent changes

Modified:
perl/modperl/trunk/Changes

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=209864r1=209863r2=209864view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri Jul  8 12:14:59 2005
@@ -12,6 +12,9 @@
 
 =item 2.0.2-dev
 
+Multiple fixes to make mod_perl 2.0 work with blead-perl (5.9.3+)
+[Stas]
+
 t/modules/reload.t would fail if run more than 3 times, breaking
 smokes [Gozer]
 




svn commit: r209871 - /perl/modperl/trunk/todo/release

2005-07-08 Thread stas
Author: stas
Date: Fri Jul  8 12:36:08 2005
New Revision: 209871

URL: http://svn.apache.org/viewcvs?rev=209871view=rev
Log:
things we need not forget to fix better

Modified:
perl/modperl/trunk/todo/release

Modified: perl/modperl/trunk/todo/release
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/todo/release?rev=209871r1=209870r2=209871view=diff
==
--- perl/modperl/trunk/todo/release (original)
+++ perl/modperl/trunk/todo/release Fri Jul  8 12:36:08 2005
@@ -9,6 +9,23 @@
 
 -
 
+The following items need more work in order to work with blead-perl:
+
+http://svn.apache.org/viewcvs?rev=209859view=rev
+perl blead fix: in 5.9.3 HvPMROOT was completely removed, temporary
+using Perl_Imodglobal_ptr(thx)))-xmg_magic (which fails on perl_clone
+from ithreads, but otherwise works). this must be replaced with a
+better solution once we find it.
+
+http://svn.apache.org/viewcvs?rev=209861view=rev
+blead perl temp fix: some recent change introduced tainting problems,
+will remove the workaround once blead perl is fixed
+
+
+
+
+-
+
 MP_STATIC_EXTS=1 must link all extensions but APR.so. At the moment
 the following are not linked:
 




svn commit: r190232 - in /perl/modperl/trunk: Changes lib/Apache2/Status.pm t/modules/apache_status.t

2005-06-12 Thread stas
Author: stas
Date: Sun Jun 12 02:38:29 2005
New Revision: 190232

URL: http://svn.apache.org/viewcvs?rev=190232view=rev
Log:
B::Terse has problems with XS code, so adjust Apache::Status to eval
{} the code doing Syntax Tree Dump: syntax and execution order options


Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Status.pm
perl/modperl/trunk/t/modules/apache_status.t

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=190232r1=190231r2=190232view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Sun Jun 12 02:38:29 2005
@@ -12,6 +12,10 @@
 
 =item 2.0.1-dev
 
+B::Terse has problems with XS code, so adjust Apache::Status to eval
+{} the code doing Syntax Tree Dump: syntax and execution order options
+[Stas]
+
 Fix a broken regexp in Apache2::Build::dir() on win32 that would
 incorrectly attempt to fully-qualify paths like c:/some/path
 [Nick *** [EMAIL PROTECTED]]

Modified: perl/modperl/trunk/lib/Apache2/Status.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Status.pm?rev=190232r1=190231r2=190232view=diff
==
--- perl/modperl/trunk/lib/Apache2/Status.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Status.pm Sun Jun 12 02:38:29 2005
@@ -497,7 +497,11 @@
 
 # XXX: blead perl dumps things to STDERR, though the same version
 # works fine with 1.27
-B::Terse::compile($arg, $name)-();
+# B::Concise couldn't parse XS code before perl patch 24681 (perl 5.9.3)
+eval { B::Terse::compile($arg, $name)-() };
+if ($@) {
+$r-print(B::Terse has failed: $@);
+}
 }
 
 sub b_terse_size_link {

Modified: perl/modperl/trunk/t/modules/apache_status.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/modules/apache_status.t?rev=190232r1=190231r2=190232view=diff
==
--- perl/modperl/trunk/t/modules/apache_status.t (original)
+++ perl/modperl/trunk/t/modules/apache_status.t Sun Jun 12 02:38:29 2005
@@ -10,7 +10,7 @@
 my @opts = qw(script myconfig rgysubs section_config env isa_tree
   symdump inc inh_tree sig);
 
-plan tests = @opts + 3, need 'HTML::HeadParser',
+plan tests = @opts + 5, need 'HTML::HeadParser',
 { CGI.pm (2.93 or higher) or Apache2::Request is needed =
   !!(eval { require CGI  $CGI::VERSION = 2.93 } ||
  eval { require Apache2::Request })};
@@ -40,4 +40,14 @@
 for my $opt (@opts) {
 my $url = $base_url?$opt;
 ok GET_BODY_ASSERT $url;
+}
+
+# B::Terse has an issue with XS, but Apache::Status shouldn't crash on
+# that
+{
+# Syntax Tree Dump: syntax and execution order options
+for (qw(slow exec)) {
+my $url = $base_url/$_/Apache2::Const::OK?noh_b_terse;
+ok GET_OK $url;
+}
 }




svn commit: r178490 - in /perl/modperl/trunk: Changes ModPerl-Registry/lib/ModPerl/RegistryCooker.pm ModPerl-Registry/t/cgi-bin/basic.pl

2005-05-25 Thread stas
Author: stas
Date: Wed May 25 10:14:46 2005
New Revision: 178490

URL: http://svn.apache.org/viewcvs?rev=178490view=rev
Log:
fix a bug in ModPerl::RegistryCooker: now stripping __(END|DATA)__
only at the beginning of the line

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm
perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/basic.pl

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=178490r1=178489r2=178490view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed May 25 10:14:46 2005
@@ -12,6 +12,9 @@
 
 =item 2.0.1-dev
 
+fix a bug in ModPerl::RegistryCooker: now stripping __(END|DATA)__
+only at the beginning of the line [Stas]
+
 APR::Base64 : [Torsten Foertsch [EMAIL PROTECTED]]
 - fix encode_len() to return the length without accounting for the
 terminating '\0' as the C API does. 

Modified: perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm?rev=178490r1=178489r2=178490view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm (original)
+++ perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm Wed May 
25 10:14:46 2005
@@ -645,7 +645,7 @@
 #
 
 sub strip_end_data_segment {
-${ +shift-{CODE} } =~ s/__(END|DATA)__(.*)//s;
+${ +shift-{CODE} } =~ s/^__(END|DATA)__(.*)//ms;
 }
 
 

Modified: perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/basic.pl
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/basic.pl?rev=178490r1=178489r2=178490view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/basic.pl (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/basic.pl Wed May 25 10:14:46 
2005
@@ -3,8 +3,13 @@
 # test all the basic functionality
 
 print Content-type: text/plain\n\n;
+
+# test that __END__ can appear in a comment w/o cutting data after it
+
 print ok $0;
 
+# test that __END__ starting at the beginning of the line makes
+# everything following it, stripped
 __END__
 
 this is some irrelevant data




svn commit: r178499 - /perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in

2005-05-25 Thread stas
Author: stas
Date: Wed May 25 10:55:20 2005
New Revision: 178499

URL: http://svn.apache.org/viewcvs?rev=178499view=rev
Log:
SetEnv requires mod_env 

Modified:
perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in

Modified: perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in?rev=178499r1=178498r2=178499view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in Wed May 25 
10:55:20 2005
@@ -203,7 +203,9 @@
 # XXX: would be nice to have Apache-Test support a new 'tmp' token
 # (similar to t_logs) which will map onto t/tmp by default and provide
 # a new -tmp option to override this default
-SetEnv TMPDIR @t_logs@
+IfModule mod_env.c
+SetEnv TMPDIR @t_logs@
+/IfModule
 # /sandbox-friendly
 
 




svn commit: r178501 - /perl/modperl/trunk/lib/ModPerl/TestReport.pm

2005-05-25 Thread stas
Author: stas
Date: Wed May 25 11:06:44 2005
New Revision: 178501

URL: http://svn.apache.org/viewcvs?rev=178501view=rev
Log:
drop the now irrelevant code dealing with Apache2/ subdirs

Modified:
perl/modperl/trunk/lib/ModPerl/TestReport.pm

Modified: perl/modperl/trunk/lib/ModPerl/TestReport.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/TestReport.pm?rev=178501r1=178500r2=178501view=diff
==
--- perl/modperl/trunk/lib/ModPerl/TestReport.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/TestReport.pm Wed May 25 11:06:44 2005
@@ -33,9 +33,7 @@
 # modules that are about to be installed
 my @skip_dirs = qw(
 blib/lib
-blib/lib/Apache2
 blib/arch
-blib/arch/Apache2
 lib
 );
 my $skip_dir_str = join '|', map { s|/|[/]|g; $_ } @skip_dirs;
@@ -43,8 +41,6 @@
 
 sub packages {
 
-# search in Apache2/ subdirs too
-eval { require Apache2 };
 my @inc = grep !/$skip_dir_pat/, @INC;
 
 my %packages = ();




svn commit: r178513 - in /perl/modperl/trunk: Changes lib/ModPerl/TestReport.pm

2005-05-25 Thread stas
Author: stas
Date: Wed May 25 12:04:14 2005
New Revision: 178513

URL: http://svn.apache.org/viewcvs?rev=178513view=rev
Log:
fix ModPerl::TestReport used by t/REPORT and mp2bug to use
ExtUtils::MakeMaker's MM-parse_version to get the interesting
packages version number, w/o trying to load them (which may fail if
the environment is not right)

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/ModPerl/TestReport.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=178513r1=178512r2=178513view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed May 25 12:04:14 2005
@@ -12,6 +12,11 @@
 
 =item 2.0.1-dev
 
+fix ModPerl::TestReport used by t/REPORT and mp2bug to use
+ExtUtils::MakeMaker's MM-parse_version to get the interesting
+packages version number, w/o trying to load them (which may fail if
+the environment is not right) [Stas]
+
 fix a bug in ModPerl::RegistryCooker: now stripping __(END|DATA)__
 only at the beginning of the line [Stas]
 

Modified: perl/modperl/trunk/lib/ModPerl/TestReport.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/TestReport.pm?rev=178513r1=178512r2=178513view=diff
==
--- perl/modperl/trunk/lib/ModPerl/TestReport.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/TestReport.pm Wed May 25 12:04:14 2005
@@ -19,6 +19,8 @@
 
 use base qw(Apache::TestReportPerl);
 
+use ExtUtils::MakeMaker ();
+
 my @interesting_packages = qw(
 CGI
 ExtUtils::MakeMaker
@@ -52,11 +54,7 @@
 for my $dir (@inc) {
 my $path = $dir/$filename;
 if (-e $path) {
-no warnings 'redefine';
-my $ver = eval { require $path;
- delete $INC{$path};
- $package-VERSION;
- };
+my $ver = MM-parse_version($path);
 # two versions could be installed (one under Apache2/)
 push @{ $packages{$package} }, $ver if $ver;
 }




svn commit: r178236 - in /perl/modperl/trunk/t: conf/ directive/ filter/ filter/TestFilter/ modules/ response/TestAPI/

2005-05-24 Thread stas
Author: stas
Date: Tue May 24 11:38:46 2005
New Revision: 178236

URL: http://svn.apache.org/viewcvs?rev=178236view=rev
Log:
make the configuration enabled if mod_mime and mod_alias are available

Modified:
perl/modperl/trunk/t/conf/extra.conf.in
perl/modperl/trunk/t/conf/extra.last.conf.in
perl/modperl/trunk/t/directive/perl.t
perl/modperl/trunk/t/filter/TestFilter/out_str_lc.pm
perl/modperl/trunk/t/filter/TestFilter/out_str_subreq_default.pm
perl/modperl/trunk/t/filter/out_str_lc.t
perl/modperl/trunk/t/filter/out_str_subreq_default.t
perl/modperl/trunk/t/modules/include.t
perl/modperl/trunk/t/modules/include2.t
perl/modperl/trunk/t/response/TestAPI/request_rec.pm
perl/modperl/trunk/t/response/TestAPI/slurp_filename.pm

Modified: perl/modperl/trunk/t/conf/extra.conf.in
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/conf/extra.conf.in?rev=178236r1=178235r2=178236view=diff
==
--- perl/modperl/trunk/t/conf/extra.conf.in (original)
+++ perl/modperl/trunk/t/conf/extra.conf.in Tue May 24 11:38:46 2005
@@ -39,7 +39,9 @@
 
 #for t/modules/include.t
 Directory @ServerRoot@/htdocs/includes
-AddOutputFilter INCLUDES .shtml
+IfModule mod_mime.c
+AddOutputFilter INCLUDES .shtml
+/IfModule
 # #virtual include of a script that sets content type is
 # considered the same as #cmd by mod_include, 
 # therefore can't use IncludesNOEXEC here
@@ -51,7 +53,9 @@
 Options +ExecCGI +IncludesNoExec
 PerlResponseHandler ModPerl::Registry
 PerlOptions +ParseHeaders +GlobalRequest
-AddOutputFilter INCLUDES .spl
+IfModule mod_mime.c
+AddOutputFilter INCLUDES .spl
+/IfModule
 /Directory
 
 IfModule mod_perl.c

Modified: perl/modperl/trunk/t/conf/extra.last.conf.in
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/conf/extra.last.conf.in?rev=178236r1=178235r2=178236view=diff
==
--- perl/modperl/trunk/t/conf/extra.last.conf.in (original)
+++ perl/modperl/trunk/t/conf/extra.last.conf.in Tue May 24 11:38:46 2005
@@ -4,13 +4,16 @@
 
 ### - ###
 Perl 
-push @Alias, ['/perl_sections', '@DocumentRoot@'];
-$Location{'/perl_sections'} = {
-'PerlInitHandler' = 'ModPerl::Test::add_config',
-'AuthType' = 'Basic',
-'AuthName' = 'PerlSection',
-'PerlAuthenHandler' = 'TestHooks::authen_basic',
+use Apache::Test ();
+if (Apache::Test::have_module('mod_alias.c')) {
+push @Alias, ['/perl_sections', '@DocumentRoot@'];
+$Location{'/perl_sections'} = {
+'PerlInitHandler' = 'ModPerl::Test::add_config',
+'AuthType' = 'Basic',
+'AuthName' = 'PerlSection',
+'PerlAuthenHandler' = 'TestHooks::authen_basic',
 };
+}
 /Perl
 
 Perl 
@@ -47,14 +50,17 @@
 
 #Deprecated access to Apache2::ReadConfig:: still works
 Perl 
-push @Apache2::ReadConfig::Alias, 
-['/perl_sections_readconfig', '@DocumentRoot@'];
-$Apache2::ReadConfig::Location{'/perl_sections_readconfig'} = {
-'PerlInitHandler'   = 'ModPerl::Test::add_config',
-'AuthType'  = 'Basic',
-'AuthName'  = 'PerlSection',
-'PerlAuthenHandler' = 'TestHooks::authen_basic',
+use Apache::Test ();
+if (Apache::Test::have_module('mod_alias.c')) {
+push @Apache2::ReadConfig::Alias, 
+['/perl_sections_readconfig', '@DocumentRoot@'];
+$Apache2::ReadConfig::Location{'/perl_sections_readconfig'} = {
+'PerlInitHandler'   = 'ModPerl::Test::add_config',
+'AuthType'  = 'Basic',
+'AuthName'  = 'PerlSection',
+'PerlAuthenHandler' = 'TestHooks::authen_basic',
 };
+}
 /Perl
 
 ### - ###

Modified: perl/modperl/trunk/t/directive/perl.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/directive/perl.t?rev=178236r1=178235r2=178236view=diff
==
--- perl/modperl/trunk/t/directive/perl.t (original)
+++ perl/modperl/trunk/t/directive/perl.t Tue May 24 11:38:46 2005
@@ -4,7 +4,7 @@
 use Apache::Test;
 use Apache::TestRequest;
 
-plan tests = 8, need need_auth, 'HTML::HeadParser';
+plan tests = 8, need need_auth, 'mod_alias.c', 'HTML::HeadParser';
 
 #so we don't have to require lwp
 my @auth = (Authorization = 'Basic ZG91Z206Zm9v'); #dougm:foo

Modified: perl/modperl/trunk/t/filter/TestFilter/out_str_lc.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/TestFilter/out_str_lc.pm?rev=178236r1=178235r2=178236view=diff
==
--- perl/modperl/trunk/t/filter/TestFilter/out_str_lc.pm (original)
+++ perl/modperl/trunk/t/filter/TestFilter/out_str_lc.pm Tue May 24 11:38:46 
2005
@@ -30,5 +30,6 @@
 Location /top_dir
   PerlOutputFilterHandler TestFilter::out_str_lc
 /Location
-
-Alias

svn commit: r178247 - in /perl/modperl/trunk/ModPerl-Registry/t: 206.t 304.t 404.t 500.t bad_scripts.t basic.t bin_resp.t cgi.t closure.t conf/extra.conf.in flush.t ithreads.t nph.t perlrun_extload.t prefork.t redirect.t special_blocks.t

2005-05-24 Thread stas
Author: stas
Date: Tue May 24 11:53:49 2005
New Revision: 178247

URL: http://svn.apache.org/viewcvs?rev=178247view=rev
Log:
deal with potentially unavailable mod_alias

Modified:
perl/modperl/trunk/ModPerl-Registry/t/206.t
perl/modperl/trunk/ModPerl-Registry/t/304.t
perl/modperl/trunk/ModPerl-Registry/t/404.t
perl/modperl/trunk/ModPerl-Registry/t/500.t
perl/modperl/trunk/ModPerl-Registry/t/bad_scripts.t
perl/modperl/trunk/ModPerl-Registry/t/basic.t
perl/modperl/trunk/ModPerl-Registry/t/bin_resp.t
perl/modperl/trunk/ModPerl-Registry/t/cgi.t
perl/modperl/trunk/ModPerl-Registry/t/closure.t
perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in
perl/modperl/trunk/ModPerl-Registry/t/flush.t
perl/modperl/trunk/ModPerl-Registry/t/ithreads.t
perl/modperl/trunk/ModPerl-Registry/t/nph.t
perl/modperl/trunk/ModPerl-Registry/t/perlrun_extload.t
perl/modperl/trunk/ModPerl-Registry/t/prefork.t
perl/modperl/trunk/ModPerl-Registry/t/redirect.t
perl/modperl/trunk/ModPerl-Registry/t/special_blocks.t

Modified: perl/modperl/trunk/ModPerl-Registry/t/206.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/206.t?rev=178247r1=178246r2=178247view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/206.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/206.t Tue May 24 11:53:49 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests = 2;
+plan tests = 2, need 'mod_alias.c';
 
 my $url = /registry/206.pl;
 my $res = GET($url);

Modified: perl/modperl/trunk/ModPerl-Registry/t/304.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/304.t?rev=178247r1=178246r2=178247view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/304.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/304.t Tue May 24 11:53:49 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests = 10;
+plan tests = 10, need 'mod_alias.c';
 
 my $url = /registry/304.pl;
 

Modified: perl/modperl/trunk/ModPerl-Registry/t/404.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/404.t?rev=178247r1=178246r2=178247view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/404.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/404.t Tue May 24 11:53:49 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET_BODY GET);
 
-plan tests = 2;
+plan tests = 2, need 'mod_alias.c';
 
 {
 t_client_log_error_is_expected();

Modified: perl/modperl/trunk/ModPerl-Registry/t/500.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/500.t?rev=178247r1=178246r2=178247view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/500.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/500.t Tue May 24 11:53:49 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests = 7;
+plan tests = 7, need 'mod_alias.c';
 
 {
 # the script changes the status before the run-time error happens,

Modified: perl/modperl/trunk/ModPerl-Registry/t/bad_scripts.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/bad_scripts.t?rev=178247r1=178246r2=178247view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/bad_scripts.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/bad_scripts.t Tue May 24 11:53:49 2005
@@ -5,7 +5,7 @@
 use Apache::TestUtil;
 use Apache::TestRequest qw(GET);
 
-plan tests = 1;
+plan tests = 1, need 'mod_alias.c';
 
 {
 t_client_log_error_is_expected();

Modified: perl/modperl/trunk/ModPerl-Registry/t/basic.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/basic.t?rev=178247r1=178246r2=178247view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/basic.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/basic.t Tue May 24 11:53:49 2005
@@ -14,7 +14,7 @@
 
 my @aliases = sort keys %modules;
 
-plan tests = @aliases * 5 + 3;
+plan tests = @aliases * 5 + 3, need 'mod_alias.c';
 
 my $vars = Apache::Test::config()-{vars};
 my $script_file = t_catfile_apache $vars-{serverroot}, 'cgi-bin', 'basic.pl';

Modified: perl/modperl/trunk/ModPerl-Registry/t/bin_resp.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/bin_resp.t?rev=178247r1=178246r2=178247view=diff
==
--- perl/modperl/trunk/ModPerl-Registry/t/bin_resp.t (original)
+++ perl/modperl/trunk/ModPerl-Registry/t/bin_resp.t Tue May 24 11:53:49 2005
@@ -7,7

svn commit: r178258 - /perl/modperl/trunk/xs/APR/Bucket/APR__Bucket.h

2005-05-24 Thread stas
Author: stas
Date: Tue May 24 12:37:32 2005
New Revision: 178258

URL: http://svn.apache.org/viewcvs?rev=178258view=rev
Log:
tidy up

Modified:
perl/modperl/trunk/xs/APR/Bucket/APR__Bucket.h

Modified: perl/modperl/trunk/xs/APR/Bucket/APR__Bucket.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/APR/Bucket/APR__Bucket.h?rev=178258r1=178257r2=178258view=diff
==
--- perl/modperl/trunk/xs/APR/Bucket/APR__Bucket.h (original)
+++ perl/modperl/trunk/xs/APR/Bucket/APR__Bucket.h Tue May 24 12:37:32 2005
@@ -103,7 +103,7 @@
 static MP_INLINE
 apr_status_t mpxs_APR__Bucket_setaside(pTHX_ SV *b_sv, SV *p_sv)
 {
-apr_pool_t *p   = mp_xs_sv2_APR__Pool(p_sv);
+apr_pool_t *p = mp_xs_sv2_APR__Pool(p_sv);
 apr_bucket *b = mp_xs_sv2_APR__Bucket(b_sv);
 apr_status_t rc = apr_bucket_setaside(b, p);
 




svn commit: r177992 - /perl/modperl/trunk/xs/tables/current/ModPerl/FunctionTable.pm

2005-05-23 Thread stas
Author: stas
Date: Mon May 23 11:17:03 2005
New Revision: 177992

URL: http://svn.apache.org/viewcvs?rev=177992view=rev
Log:
source_scan sync

Modified:
perl/modperl/trunk/xs/tables/current/ModPerl/FunctionTable.pm

Modified: perl/modperl/trunk/xs/tables/current/ModPerl/FunctionTable.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/tables/current/ModPerl/FunctionTable.pm?rev=177992r1=177991r2=177992view=diff
==
--- perl/modperl/trunk/xs/tables/current/ModPerl/FunctionTable.pm (original)
+++ perl/modperl/trunk/xs/tables/current/ModPerl/FunctionTable.pm Mon May 23 
11:17:03 2005
@@ -2,7 +2,7 @@
 
 # !!
 # ! WARNING: generated by ModPerl::ParseSource/0.01
-# !  Thu Jan  6 11:25:08 2005
+# !  Mon May 23 14:15:47 2005
 # !  do NOT edit, any changes will be lost !
 # !!
 
@@ -7207,6 +7207,24 @@
 ]
   },
   {
+'return_type' = 'request_rec *',
+'name' = 'mpxs_Apache2__RequestUtil_request',
+'args' = [
+  {
+'type' = 'PerlInterpreter *',
+'name' = 'my_perl'
+  },
+  {
+'type' = 'SV *',
+'name' = 'classname'
+  },
+  {
+'type' = 'SV *',
+'name' = 'svr'
+  }
+]
+  },
+  {
 'return_type' = 'void',
 'name' = 'mpxs_Apache2__ServerRec_add_config',
 'args' = [
@@ -7332,24 +7350,6 @@
   {
 'type' = 'SV *',
 'name' = 'arg'
-  }
-]
-  },
-  {
-'return_type' = 'request_rec *',
-'name' = 'mpxs_Apache2__RequestUtil_request',
-'args' = [
-  {
-'type' = 'PerlInterpreter *',
-'name' = 'my_perl'
-  },
-  {
-'type' = 'SV *',
-'name' = 'classname'
-  },
-  {
-'type' = 'SV *',
-'name' = 'svr'
   }
 ]
   },




svn commit: r177993 - /perl/modperl/trunk/xs/tables/current/Apache2/FunctionTable.pm

2005-05-23 Thread stas
Author: stas
Date: Mon May 23 11:17:29 2005
New Revision: 177993

URL: http://svn.apache.org/viewcvs?rev=177993view=rev
Log:
source_scan sync

Modified:
perl/modperl/trunk/xs/tables/current/Apache2/FunctionTable.pm

Modified: perl/modperl/trunk/xs/tables/current/Apache2/FunctionTable.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/tables/current/Apache2/FunctionTable.pm?rev=177993r1=177992r2=177993view=diff
==
--- perl/modperl/trunk/xs/tables/current/Apache2/FunctionTable.pm (original)
+++ perl/modperl/trunk/xs/tables/current/Apache2/FunctionTable.pm Mon May 23 
11:17:29 2005
@@ -1,8 +1,8 @@
 package Apache2::FunctionTable;
 
 # !!
-# ! WARNING: generated by Apache::ParseSource/0.02
-# !  Fri Dec 10 14:14:09 2004
+# ! WARNING: generated by Apache2::ParseSource/0.02
+# !  Mon May 23 14:15:40 2005
 # !  do NOT edit, any changes will be lost !
 # !!
 
@@ -4326,6 +4326,16 @@
   },
   {
 'return_type' = 'void',
+'name' = 'ap_register_extra_mpm_process',
+'args' = [
+  {
+'type' = 'pid_t',
+'name' = 'pid'
+  }
+]
+  },
+  {
+'return_type' = 'void',
 'name' = 'ap_register_hooks',
 'args' = [
   {
@@ -5904,12 +5914,8 @@
 'name' = 'ap_time_process_request',
 'args' = [
   {
-'type' = 'int',
-'name' = 'child_num'
-  },
-  {
-'type' = 'int',
-'name' = 'thread_num'
+'type' = 'ap_sb_handle_t *',
+'name' = 'sbh'
   },
   {
 'type' = 'int',
@@ -5944,6 +5950,16 @@
   {
 'type' = 'char *',
 'name' = 'url'
+  }
+]
+  },
+  {
+'return_type' = 'int',
+'name' = 'ap_unregister_extra_mpm_process',
+'args' = [
+  {
+'type' = 'pid_t',
+'name' = 'pid'
   }
 ]
   },




svn commit: r177994 - in /perl/modperl/trunk: Changes lib/Apache2/ParseSource.pm xs/tables/current/Apache2/ConstantsTable.pm

2005-05-23 Thread stas
Author: stas
Date: Mon May 23 11:22:36 2005
New Revision: 177994

URL: http://svn.apache.org/viewcvs?rev=177994view=rev
Log:
Expose Apache2::Const::EXEC_ON_READ (added to the :override group)

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/ParseSource.pm
perl/modperl/trunk/xs/tables/current/Apache2/ConstantsTable.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=177994r1=177993r2=177994view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon May 23 11:22:36 2005
@@ -12,6 +12,9 @@
 
 =item 2.0.1-dev
 
+Expose Apache2::Const::EXEC_ON_READ (added to the :override group)
+[Stas]
+
 Fix a bug in custom directive implementation, where the code called
 from modperl_module_config_merge() was setting the global context
 after selecting the new interpreter which was leading to a segfault in

Modified: perl/modperl/trunk/lib/Apache2/ParseSource.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/ParseSource.pm?rev=177994r1=177993r2=177994view=diff
==
--- perl/modperl/trunk/lib/Apache2/ParseSource.pm (original)
+++ perl/modperl/trunk/lib/Apache2/ParseSource.pm Mon May 23 11:22:36 2005
@@ -236,7 +236,7 @@
 methods= [qw{M_ METHODS}],
 mpmq   = [qw{AP_MPMQ_}],
 options= [qw{OPT_}],
-override   = [qw{OR_ ACCESS_CONF RSRC_CONF}],
+override   = [qw{OR_ EXEC_ON_READ ACCESS_CONF RSRC_CONF}],
 platform   = [qw{CRLF CR LF}],
 remotehost = [qw{REMOTE_}],
 satisfy= [qw{SATISFY_}],

Modified: perl/modperl/trunk/xs/tables/current/Apache2/ConstantsTable.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/tables/current/Apache2/ConstantsTable.pm?rev=177994r1=177993r2=177994view=diff
==
--- perl/modperl/trunk/xs/tables/current/Apache2/ConstantsTable.pm (original)
+++ perl/modperl/trunk/xs/tables/current/Apache2/ConstantsTable.pm Mon May 23 
11:22:36 2005
@@ -1,8 +1,8 @@
 package Apache2::ConstantsTable;
 
 # !!
-# ! WARNING: generated by Apache::ParseSource/0.02
-# !  Fri Dec 10 13:39:12 2004
+# ! WARNING: generated by Apache2::ParseSource/0.02
+# !  Mon May 23 14:15:32 2005
 # !  do NOT edit, any changes will be lost !
 # !!
 
@@ -42,6 +42,7 @@
   'OR_UNSET',
   'ACCESS_CONF',
   'RSRC_CONF',
+  'EXEC_ON_READ',
   'OR_ALL'
 ],
 'options' = [




svn commit: r178047 - in /perl/modperl/trunk: Changes src/modules/perl/modperl_callback.c

2005-05-23 Thread stas
Author: stas
Date: Mon May 23 15:34:19 2005
New Revision: 178047

URL: http://svn.apache.org/viewcvs?rev=178047view=rev
Log:
in mod_perl callbacks merge error-notes entries rather than store just
the newest error

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_callback.c

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=178047r1=178046r2=178047view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon May 23 15:34:19 2005
@@ -12,6 +12,9 @@
 
 =item 2.0.1-dev
 
+in mod_perl callbacks merge error-notes entries rather than store just
+the newest error [Mark [EMAIL PROTECTED]]
+
 Expose Apache2::Const::EXEC_ON_READ (added to the :override group)
 [Stas]
 

Modified: perl/modperl/trunk/src/modules/perl/modperl_callback.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_callback.c?rev=178047r1=178046r2=178047view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_callback.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_callback.c Mon May 23 15:34:19 
2005
@@ -130,7 +130,7 @@
 
 if (status == HTTP_INTERNAL_SERVER_ERROR) {
 if (r  r-notes) {
-apr_table_set(r-notes, error-notes, SvPV_nolen(ERRSV));
+apr_table_mergen(r-notes, error-notes, SvPV_nolen(ERRSV));
 }
 }
 




svn commit: r171168 - in /perl/modperl/trunk: Changes src/modules/perl/modperl_module.c t/directive/ t/response/TestDirective/perlloadmodule7.pm

2005-05-20 Thread stas
Author: stas
Date: Fri May 20 16:01:03 2005
New Revision: 171168

URL: http://svn.apache.org/viewcvs?rev=171168view=rev
Log:

Fix a bug in custom directive implementation, where a custom directive
placed into a dir container was causing a global perl context change
which was leading to a segfault in any handler called
thereafter.

Added:
perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm   (with 
props)
Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_module.c
perl/modperl/trunk/t/directive/   (props changed)

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=171168r1=171167r2=171168view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri May 20 16:01:03 2005
@@ -12,6 +12,11 @@
 
 =item 2.0.1-dev
 
+Fix a bug in custom directive implementation, where a custom directive
+placed into a dir container was causing a global perl context change
+which was leading to a segfault in any handler called
+thereafter. [Stas]
+
 
 =item 2.0.0 - May 20, 2005
 

Modified: perl/modperl/trunk/src/modules/perl/modperl_module.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_module.c?rev=171168r1=171167r2=171168view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_module.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_module.c Fri May 20 16:01:03 
2005
@@ -165,10 +165,9 @@
 int is_startup;
 PTR_TBL_t *table;
 SV *mrg_obj = Nullsv, *base_obj, *add_obj;
-
 #ifdef USE_ITHREADS
+MP_PERL_CONTEXT_DECLARE;
 modperl_interp_t *interp;
-pTHX;
 #endif
 
 /* if the module is loaded in vhost, base==NULL */
@@ -184,7 +183,7 @@
 
 #ifdef USE_ITHREADS
 interp = modperl_interp_pool_select(p, s);
-aTHX = interp-perl;
+MP_PERL_CONTEXT_STORE_OVERRIDE(interp-perl);
 #endif
 
 table = modperl_module_config_table_get(aTHX_ TRUE);
@@ -240,6 +239,11 @@
 modperl_module_config_obj_cleanup_register(aTHX_ p, table, mrg);
 }
 
+#ifdef USE_ITHREADS
+modperl_interp_unselect(interp);
+MP_PERL_CONTEXT_RESTORE;
+#endif
+
 return (void *)mrg;
 }
 

Propchange: perl/modperl/trunk/t/directive/
--
--- svn:ignore (original)
+++ svn:ignore Fri May 20 16:01:03 2005
@@ -1,5 +1,6 @@
 cmdparms.t
 env.t
 perlloadmodule.t
+perlloadmodule7.t
 pod.t
 perldo.t

Added: perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm?rev=171168view=auto
==
--- perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm (added)
+++ perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm Fri May 20 
16:01:03 2005
@@ -0,0 +1,56 @@
+package TestDirective::perlloadmodule7;
+
+# in this test we test an early mod_perl startup caused by an
+# EXEC_ON_READ directive in vhost.
+
+use strict;
+use warnings FATAL = 'all';
+
+use Apache2::Module ();
+
+use Apache2::Const -compile = qw(OK);
+
+use constant KEY = MyTest7;
+
+my @directives = ({ name = +KEY },);
+
+Apache2::Module::add(__PACKAGE__, [EMAIL PROTECTED]);
+
+sub MyTest7 {
+my($self, $parms, $arg) = @_;
+$self-{+KEY} = $arg;
+}
+
+### response handler ###
+
+use Apache2::RequestRec ();
+use Apache2::RequestIO ();
+
+use Apache::Test;
+use Apache::TestUtil;
+
+use Apache2::Const -compile = qw(OK);
+
+sub handler {
+my($r) = @_;
+
+plan $r, tests = 1;
+
+ok 1;
+
+return Apache2::Const::OK;
+}
+
+1;
+__END__
+
+NoAutoConfig
+# APACHE_TEST_CONFIG_ORDER 950
+PerlLoadModule TestDirective::perlloadmodule7
+
+Location /TestDirective__perlloadmodule7
+MyTest7 test
+SetHandler modperl
+PerlResponseHandler TestDirective::perlloadmodule7
+/Location
+/NoAutoConfig

Propchange: perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm
--
svn:eol-style = native




svn commit: r171189 - in /perl/modperl/trunk: Changes src/modules/perl/modperl_module.c t/response/TestDirective/perlloadmodule7.pm

2005-05-20 Thread stas
Author: stas
Date: Fri May 20 19:58:13 2005
New Revision: 171189

URL: http://svn.apache.org/viewcvs?rev=171189view=rev
Log:
fix the half-baked fix and extend the test

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_module.c
perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=171189r1=171188r2=171189view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri May 20 19:58:13 2005
@@ -12,10 +12,12 @@
 
 =item 2.0.1-dev
 
-Fix a bug in custom directive implementation, where a custom directive
-placed into a dir container was causing a global perl context change
-which was leading to a segfault in any handler called
-thereafter. [Stas]
+Fix a bug in custom directive implementation, where the code called
+from modperl_module_config_merge() was setting the global context
+after selecting the new interpreter which was leading to a segfault in
+any handler called thereafter, whose context was different
+beforehand. [Stas]
+
 
 
 =item 2.0.0 - May 20, 2005

Modified: perl/modperl/trunk/src/modules/perl/modperl_module.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_module.c?rev=171189r1=171188r2=171189view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_module.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_module.c Fri May 20 19:58:13 
2005
@@ -191,6 +191,12 @@
 add_obj  = modperl_svptr_table_fetch(aTHX_ table, add);
 
 if (!base_obj || (base_obj == add_obj)) {
+#ifdef USE_ITHREADS
+modperl_interp_unselect(interp);
+if (orig_perl) {
+MP_PERL_CONTEXT_RESTORE;
+}
+#endif
 return addv;
 }
 
@@ -241,7 +247,9 @@
 
 #ifdef USE_ITHREADS
 modperl_interp_unselect(interp);
-MP_PERL_CONTEXT_RESTORE;
+if (orig_perl) {
+MP_PERL_CONTEXT_RESTORE;
+}
 #endif
 
 return (void *)mrg;

Modified: perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm?rev=171189r1=171188r2=171189view=diff
==
--- perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm (original)
+++ perl/modperl/trunk/t/response/TestDirective/perlloadmodule7.pm Fri May 20 
19:58:13 2005
@@ -1,7 +1,11 @@
 package TestDirective::perlloadmodule7;
 
-# in this test we test an early mod_perl startup caused by an
-# EXEC_ON_READ directive in vhost.
+# this test was written to reproduce a segfault under worker
+# due to a bug in custom directive implementation, where
+# the code called from modperl_module_config_merge() was setting the
+# global context after selecting the new interpreter which was leading
+# to a segfault in any handler called thereafter, whose context was
+# different beforehand.
 
 use strict;
 use warnings FATAL = 'all';
@@ -10,15 +14,21 @@
 
 use Apache2::Const -compile = qw(OK);
 
-use constant KEY = MyTest7;
+use constant KEY1 = MyTest7_1;
+use constant KEY2 = MyTest7_2;
 
-my @directives = ({ name = +KEY },);
+my @directives = ({ name = +KEY1 }, { name = +KEY2 });
 
 Apache2::Module::add(__PACKAGE__, [EMAIL PROTECTED]);
 
-sub MyTest7 {
+sub MyTest7_1 {
 my($self, $parms, $arg) = @_;
-$self-{+KEY} = $arg;
+$self-{+KEY1} = $arg;
+}
+
+sub MyTest7_2 {
+my($self, $parms, $arg) = @_;
+$self-{+KEY2} = $arg;
 }
 
 ### response handler ###
@@ -48,8 +58,9 @@
 # APACHE_TEST_CONFIG_ORDER 950
 PerlLoadModule TestDirective::perlloadmodule7
 
+MyTest7_1 test
 Location /TestDirective__perlloadmodule7
-MyTest7 test
+MyTest7_2 test
 SetHandler modperl
 PerlResponseHandler TestDirective::perlloadmodule7
 /Location




svn commit: r171192 - /perl/modperl/trunk/src/modules/perl/mod_perl.h /perl/modperl/trunk/src/modules/perl/modperl_module.c

2005-05-20 Thread stas
Author: stas
Date: Fri May 20 20:32:14 2005
New Revision: 171192

URL: http://svn.apache.org/viewcvs?rev=171192view=rev
Log:
move the if (orig_perl) check into the macro, so other places can benefit from 
it

Modified:
perl/modperl/trunk/src/modules/perl/mod_perl.h
perl/modperl/trunk/src/modules/perl/modperl_module.c

Modified: perl/modperl/trunk/src/modules/perl/mod_perl.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/mod_perl.h?rev=171192r1=171191r2=171192view=diff
==
--- perl/modperl/trunk/src/modules/perl/mod_perl.h (original)
+++ perl/modperl/trunk/src/modules/perl/mod_perl.h Fri May 20 20:32:14 2005
@@ -169,7 +169,7 @@
 #ifdef USE_ITHREADS
 
 #define MP_PERL_CONTEXT_DECLARE \
-PerlInterpreter *orig_perl; \
+PerlInterpreter *orig_perl = NULL;  \
 pTHX;
 
 #define MP_PERL_CONTEXT_STORE   \
@@ -184,7 +184,9 @@
 MP_PERL_CONTEXT_OVERRIDE(new_perl)
 
 #define MP_PERL_CONTEXT_RESTORE \
-PERL_SET_CONTEXT(orig_perl);
+if (orig_perl) {\
+PERL_SET_CONTEXT(orig_perl);\
+}
 
 #else /* #ifdef USE_ITHREADS */
 

Modified: perl/modperl/trunk/src/modules/perl/modperl_module.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_module.c?rev=171192r1=171191r2=171192view=diff
==
--- perl/modperl/trunk/src/modules/perl/modperl_module.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_module.c Fri May 20 20:32:14 
2005
@@ -194,9 +194,7 @@
 #ifdef USE_ITHREADS
 /* XXX: breaks prefork
modperl_interp_unselect(interp); */
-if (orig_perl) {
-MP_PERL_CONTEXT_RESTORE;
-}
+MP_PERL_CONTEXT_RESTORE;
 #endif
 return addv;
 }
@@ -249,9 +247,7 @@
 #ifdef USE_ITHREADS
 /* XXX: breaks prefork
modperl_interp_unselect(interp); */
-if (orig_perl) {
-MP_PERL_CONTEXT_RESTORE;
-}
+MP_PERL_CONTEXT_RESTORE;
 #endif
 
 return (void *)mrg;




cvs commit: modperl/Apache Apache.pm

2005-05-17 Thread stas
stas2005/05/16 14:27:32

  Modified:Apache   Apache.pm
  Log:
  $c-user is deprecated, $r-user should be used instead
  Submitted by: Ville Skyttä [EMAIL PROTECTED]
  
  Revision  ChangesPath
  1.77  +9 -5  modperl/Apache/Apache.pm
  
  Index: Apache.pm
  ===
  RCS file: /home/cvs/modperl/Apache/Apache.pm,v
  retrieving revision 1.76
  retrieving revision 1.77
  diff -u -u -r1.76 -r1.77
  --- Apache.pm 22 Jul 2004 19:56:26 -  1.76
  +++ Apache.pm 16 May 2005 21:27:32 -  1.77
  @@ -467,6 +467,12 @@
   remote system is not running an RFC 1413 server or if the configuration
   directive BIdentityCheck is not turned on.
   
  +=item $r-Egtuser( [$user] )
  +
  +If an authentication check was successful, the authentication handler
  +caches the user name here. Sets the user name to the optional first
  +argument.
  +
   =back
   
   More information about the client can be obtained from the
  @@ -554,14 +560,12 @@
   
   =item $c-Egtuser( [$user] )
   
  -If an authentication check was successful, the authentication handler
  -caches the user name here. Sets the user name to the optional first
  -argument.
  +Deprecated, use C$r-Egtuser instead.
   
   =item $c-Egtauth_type
   
  -Returns the authentication scheme that successfully authenticate
  -C$c-Egtuser, if any.
  +Returns the authentication scheme used to successfully authenticate
  +C$r-Egtuser, if any.
   
   =item $c-Egtaborted
   
  
  
  


svn commit: r170620 - in /perl/modperl/trunk/t: modperl/setupenv.t response/TestModperl/setupenv.pm

2005-05-17 Thread stas
Author: stas
Date: Tue May 17 10:27:10 2005
New Revision: 170620

URL: http://svn.apache.org/viewcvs?rev=170620view=rev
Log:
SetEnv requires mod_env

Modified:
perl/modperl/trunk/t/modperl/setupenv.t
perl/modperl/trunk/t/response/TestModperl/setupenv.pm

Modified: perl/modperl/trunk/t/modperl/setupenv.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/modperl/setupenv.t?rev=170620r1=170619r2=170620view=diff
==
--- perl/modperl/trunk/t/modperl/setupenv.t (original)
+++ perl/modperl/trunk/t/modperl/setupenv.t Tue May 17 10:27:10 2005
@@ -26,7 +26,7 @@
 # this requires keepalives and a per-connection interpreter
 # to make certain we can plan in one request and test in another
 # which requires LWP
-unless (need_lwp()) {
+unless (need_lwp()  need_module('mod_env')) {
 plan tests = 63, 0;
 }
 

Modified: perl/modperl/trunk/t/response/TestModperl/setupenv.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestModperl/setupenv.pm?rev=170620r1=170619r2=170620view=diff
==
--- perl/modperl/trunk/t/response/TestModperl/setupenv.pm (original)
+++ perl/modperl/trunk/t/response/TestModperl/setupenv.pm Tue May 17 10:27:10 
2005
@@ -190,7 +190,9 @@
 PerlPostReadRequestHandler TestModperl::setupenv::subenv_one
 
 # SetEnv is affected by +SetupEnv
-SetEnv SRV_SETENV server
+IfModule mod_env.c
+SetEnv SRV_SETENV server
+/IfModule
 
 # PerlSetEnv is not affected by +SetupEnv or -SetupEnv
 # it is entirely separate and always set if configured
@@ -210,8 +212,9 @@
 PerlResponseHandler TestModperl::setupenv::noenv
 
 PerlFixupHandler TestModperl::setupenv::subenv_two
-
-SetEnv DIR_SETENV mpdefault
+IfModule mod_env.c
+SetEnv DIR_SETENV mpdefault
+/IfModule
 PerlSetEnv DIR_PERLSETENV mpdefault
 /Location
 
@@ -226,7 +229,9 @@
 
 PerlFixupHandler TestModperl::setupenv::subenv_two
 
-SetEnv DIR_SETENV mpsetup
+IfModule mod_env.c
+SetEnv DIR_SETENV mpsetup
+/IfModule
 PerlSetEnv DIR_PERLSETENV mpsetup
 /Location
 
@@ -242,7 +247,9 @@
 PerlHeaderParserHandler TestModperl::setupenv::subenv_void
 PerlFixupHandler TestModperl::setupenv::subenv_two
 
-SetEnv DIR_SETENV mpvoid
+IfModule mod_env.c
+SetEnv DIR_SETENV mpvoid
+/IfModule
 PerlSetEnv DIR_PERLSETENV mpvoid
 /Location
 
@@ -260,7 +267,9 @@
 PerlHeaderParserHandler TestModperl::setupenv::subenv_void
 PerlFixupHandler TestModperl::setupenv::subenv_two
 
-SetEnv DIR_SETENV mpsetupvoid
+IfModule mod_env.c
+SetEnv DIR_SETENV mpsetupvoid
+/IfModule
 PerlSetEnv DIR_PERLSETENV mpsetupvoid
 /Location
 
@@ -272,7 +281,9 @@
 
 PerlFixupHandler TestModperl::setupenv::subenv_two
 
-SetEnv DIR_SETENV psdefault
+IfModule mod_env.c
+SetEnv DIR_SETENV psdefault
+/IfModule
 PerlSetEnv DIR_PERLSETENV psdefault
 /Location
 
@@ -286,7 +297,9 @@
 
 PerlFixupHandler TestModperl::setupenv::subenv_two
 
-SetEnv DIR_SETENV psnosetup
+IfModule mod_env.c
+SetEnv DIR_SETENV psnosetup
+/IfModule
 PerlSetEnv DIR_PERLSETENV psnosetup
 /Location
 
@@ -302,7 +315,9 @@
 PerlHeaderParserHandler TestModperl::setupenv::subenv_void
 PerlFixupHandler TestModperl::setupenv::subenv_two
 
-SetEnv DIR_SETENV psvoid
+IfModule mod_env.c
+SetEnv DIR_SETENV psvoid
+/IfModule
 PerlSetEnv DIR_PERLSETENV psvoid
 /Location
 
@@ -318,7 +333,9 @@
 PerlHeaderParserHandler TestModperl::setupenv::subenv_void
 PerlFixupHandler TestModperl::setupenv::subenv_two
 
-SetEnv DIR_SETENV psnosetupvoid
+IfModule mod_env.c
+SetEnv DIR_SETENV psnosetupvoid
+/IfModule
 PerlSetEnv DIR_PERLSETENV psnosetupvoid
 /Location
 /VirtualHost




svn commit: r170098 - /perl/modperl/trunk/lib/Bundle/Apache2.pm

2005-05-13 Thread stas
Author: stas
Date: Fri May 13 14:56:17 2005
New Revision: 170098

URL: http://svn.apache.org/viewcvs?rev=170098view=rev
Log:
CGI  3.10 is out, has some fixed needed by mp2.

Modified:
perl/modperl/trunk/lib/Bundle/Apache2.pm

Modified: perl/modperl/trunk/lib/Bundle/Apache2.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Bundle/Apache2.pm?rev=170098r1=170097r2=170098view=diff
==
--- perl/modperl/trunk/lib/Bundle/Apache2.pm (original)
+++ perl/modperl/trunk/lib/Bundle/Apache2.pm Fri May 13 14:56:17 2005
@@ -36,7 +36,7 @@
 
 Bundle::ApacheTest- Needs for testing
 
-CGI  3.08 - Used in testing (it's in core, but some vendors 
exclude it)
+CGI  3.10 - Used in testing (it's in core, but some vendors 
exclude it)
 
 Chatbot::Eliza- Used in testing
 




svn commit: r170111 - in /perl/modperl/trunk: Changes Makefile.PL

2005-05-13 Thread stas
Author: stas
Date: Fri May 13 17:07:07 2005
New Revision: 170111

URL: http://svn.apache.org/viewcvs?rev=170111view=rev
Log:
fix the ap_install target in the top-level Makefile (used for static
build)

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/Makefile.PL

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=170111r1=170110r2=170111view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri May 13 17:07:07 2005
@@ -12,6 +12,9 @@
 
 =item 2.000_00-dev
 
+fix the ap_install target in the top-level Makefile (used for static
+build) [Stas]
+
 Reintroduce a pure-Perl version of ModPerl::Util::unload_package()
 The problematic XS version is now called unload_package_xs() and
 not used by default [Gozer]

Modified: perl/modperl/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Makefile.PL?rev=170111r1=170110r2=170111view=diff
==
--- perl/modperl/trunk/Makefile.PL (original)
+++ perl/modperl/trunk/Makefile.PL Fri May 13 17:07:07 2005
@@ -641,12 +641,12 @@
 $string .= EOF;
 ap_build: modperl_lib
cd $build-{MP_AP_PREFIX}  make
-
+
 ap_install: ap_build
-   cd $build-{MP_AP_PREFIX}  make DESTDIR=$(DESTDIR) install
+   cd $build-{MP_AP_PREFIX}  make DESTDIR=\$(DESTDIR) install
 EOF
 }
-
+
 ModPerl::MM::add_dep(\$string, pure_all = 'modperl_lib');
 
 $string .= 'EOF';




svn commit: r169644 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm

2005-05-11 Thread stas
Author: stas
Date: Wed May 11 08:14:51 2005
New Revision: 169644

URL: http://svn.apache.org/viewcvs?rev=169644view=rev
Log:
make sure that the build picks up the include directories based on the
apxs queries and only search the httpd source if $self-{MP_AP_PREFIX}
was set. Earlier it was always picking the headers from the httpd
source if it was available, which was resulting in the wrong headers
if the installed httpd was different than the source that was found

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=169644r1=169643r2=169644view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed May 11 08:14:51 2005
@@ -12,6 +12,13 @@
 
 =item 1.999_24-dev
 
+make sure that the build picks up the include directories based on the
+apxs queries and only search the httpd source if $self-{MP_AP_PREFIX}
+was set. Earlier it was always picking the headers from the httpd
+source if it was available, which was resulting in the wrong headers
+if the installed httpd was different than the source that was found
+[Stas]
+
 introduce ModPerl::RegistryPrefork and ModPerl::PerlRunPrefork, which
 behave the same as ModPerl::Registry and ModPerl::PerlRun,
 respectively, but chdir to the script's directory like mod_cgi

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=169644r1=169643r2=169644view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Wed May 11 08:14:51 2005
@@ -940,7 +940,8 @@
 
 return $self-{dir} if $self-{dir};
 
-if (IS_MOD_PERL_BUILD) {
+# be careful with the guesswork, or may pick up some wrong headers
+if (IS_MOD_PERL_BUILD  $self-{MP_AP_PREFIX}) {
 my $build = $self-build_config;
 
 if (my $bdir = $build-{'dir'}) {
@@ -1927,7 +1928,6 @@
 die Can't find the mod_perl include dir (reason: $reason);
 }
 
-my $src = $self-dir;
 my $os = WIN32 ? 'win32' : 'unix';
 push @inc, $self-file_path(src/modules/perl, xs);
 
@@ -1951,13 +1951,16 @@
 }
 }
 
-for ($src/modules/perl, $src/include,
- $src/srclib/apr/include,
- $src/srclib/apr-util/include,
- $src/os/$os)
-  {
-  push @inc, $_ if -d $_;
-  }
+if ($self-{MP_AP_PREFIX}) {
+my $src = $self-dir;
+for ($src/modules/perl, $src/include,
+ $src/srclib/apr/include,
+ $src/srclib/apr-util/include,
+ $src/os/$os)
+{
+push @inc, $_ if -d $_;
+}
+}
 
 return [EMAIL PROTECTED];
 }




Re: svn commit: r169644 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm

2005-05-11 Thread Stas Bekman
Philip M. Gollucci wrote:
[EMAIL PROTECTED] wrote:
Author: stas
Date: Wed May 11 08:14:51 2005
New Revision: 169644
URL: http://svn.apache.org/viewcvs?rev=169644view=rev
Log:
make sure that the build picks up the include directories based on the
apxs queries and only search the httpd source if $self-{MP_AP_PREFIX}
was set. Earlier it was always picking the headers from the httpd
source if it was available, which was resulting in the wrong headers
if the installed httpd was different than the source that was found
 

JackPot!
Stas, that fixed my incorrect linking stuff I was talking about
with linking in threaded stuff even though the one I told mp2 about was 
not threaded.

Thanks!
:)
--
__
Stas BekmanJAm_pH -- Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide --- http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com


svn commit: r169710 - /perl/modperl/trunk/xs/APR/Status/APR__Status.h

2005-05-11 Thread stas
Author: stas
Date: Wed May 11 15:55:53 2005
New Revision: 169710

URL: http://svn.apache.org/viewcvs?rev=169710view=rev
Log:
align

Modified:
perl/modperl/trunk/xs/APR/Status/APR__Status.h

Modified: perl/modperl/trunk/xs/APR/Status/APR__Status.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/APR/Status/APR__Status.h?rev=169710r1=169709r2=169710view=diff
==
--- perl/modperl/trunk/xs/APR/Status/APR__Status.h (original)
+++ perl/modperl/trunk/xs/APR/Status/APR__Status.h Wed May 11 15:55:53 2005
@@ -15,9 +15,9 @@
 
 #include apr_errno.h
 
-#define mpxs_APR__Status_is_EAGAIN APR_STATUS_IS_EAGAIN
-#define mpxs_APR__Status_is_EACCES APR_STATUS_IS_EACCES
-#define mpxs_APR__Status_is_ENOENT APR_STATUS_IS_ENOENT
-#define mpxs_APR__Status_is_EOF APR_STATUS_IS_EOF
+#define mpxs_APR__Status_is_EAGAIN   APR_STATUS_IS_EAGAIN
+#define mpxs_APR__Status_is_EACCES   APR_STATUS_IS_EACCES
+#define mpxs_APR__Status_is_ENOENT   APR_STATUS_IS_ENOENT
+#define mpxs_APR__Status_is_EOF  APR_STATUS_IS_EOF
 #define mpxs_APR__Status_is_ECONNABORTED APR_STATUS_IS_ECONNABORTED
-#define mpxs_APR__Status_is_TIMEUP APR_STATUS_IS_TIMEUP
+#define mpxs_APR__Status_is_TIMEUP   APR_STATUS_IS_TIMEUP




svn commit: r169713 - in /perl/modperl/trunk: Changes t/protocol/TestProtocol/echo_nonblock.pm xs/APR/Status/APR__Status.h xs/maps/apr_functions.map

2005-05-11 Thread stas
Author: stas
Date: Wed May 11 16:04:04 2005
New Revision: 169713

URL: http://svn.apache.org/viewcvs?rev=169713view=rev
Log:
add APR::Status::is_ECONNRESET

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/t/protocol/TestProtocol/echo_nonblock.pm
perl/modperl/trunk/xs/APR/Status/APR__Status.h
perl/modperl/trunk/xs/maps/apr_functions.map

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=169713r1=169712r2=169713view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed May 11 16:04:04 2005
@@ -12,6 +12,12 @@
 
 =item 1.999_24-dev
 
+More APR::Status wrappers:  [Stas, Randy Kobes]
+- is_EOF
+- is_ECONNABORTED
+- is_ECONNRESET
+- is_TIMEUP
+
 make sure that the build picks up the include directories based on the
 apxs queries and only search the httpd source if $self-{MP_AP_PREFIX}
 was set. Earlier it was always picking the headers from the httpd

Modified: perl/modperl/trunk/t/protocol/TestProtocol/echo_nonblock.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/protocol/TestProtocol/echo_nonblock.pm?rev=169713r1=169712r2=169713view=diff
==
--- perl/modperl/trunk/t/protocol/TestProtocol/echo_nonblock.pm (original)
+++ perl/modperl/trunk/t/protocol/TestProtocol/echo_nonblock.pm Wed May 11 
16:04:04 2005
@@ -42,8 +42,12 @@
 my $buf;
 my $len = eval { $socket-recv($buf, BUFF_LEN) };
 if ($@) {
+# rethrow
 die $@ unless ref $@ eq 'APR::Error'
- APR::Status::is_ECONNABORTED($@); # rethrow
+ (APR::Status::is_ECONNABORTED($@) ||
+APR::Status::is_ECONNRESET($@));
+# ECONNABORTED == 103
+# ECONNRESET   == 104
 # ECONNABORTED is not an application error
 # XXX: we don't really test that we always get this
 # condition, since it depends on the timing of the

Modified: perl/modperl/trunk/xs/APR/Status/APR__Status.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/APR/Status/APR__Status.h?rev=169713r1=169712r2=169713view=diff
==
--- perl/modperl/trunk/xs/APR/Status/APR__Status.h (original)
+++ perl/modperl/trunk/xs/APR/Status/APR__Status.h Wed May 11 16:04:04 2005
@@ -20,4 +20,5 @@
 #define mpxs_APR__Status_is_ENOENT   APR_STATUS_IS_ENOENT
 #define mpxs_APR__Status_is_EOF  APR_STATUS_IS_EOF
 #define mpxs_APR__Status_is_ECONNABORTED APR_STATUS_IS_ECONNABORTED
+#define mpxs_APR__Status_is_ECONNRESET   APR_STATUS_IS_ECONNRESET
 #define mpxs_APR__Status_is_TIMEUP   APR_STATUS_IS_TIMEUP

Modified: perl/modperl/trunk/xs/maps/apr_functions.map
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/maps/apr_functions.map?rev=169713r1=169712r2=169713view=diff
==
--- perl/modperl/trunk/xs/maps/apr_functions.map (original)
+++ perl/modperl/trunk/xs/maps/apr_functions.map Wed May 11 16:04:04 2005
@@ -653,4 +653,5 @@
  int:DEFINE_is_ENOENT   | | apr_status_t:rc
  int:DEFINE_is_EOF  | | apr_status_t:rc
  int:DEFINE_is_ECONNABORTED | | apr_status_t:rc
+ int:DEFINE_is_ECONNRESET   | | apr_status_t:rc
  int:DEFINE_is_TIMEUP   | | apr_status_t:rc




svn commit: r169560 - in /perl/modperl/trunk: Changes ModPerl-Registry/lib/ModPerl/PerlRunPrefork.pm ModPerl-Registry/lib/ModPerl/RegistryPrefork.pm ModPerl-Registry/t/cgi-bin/prefork.pl ModPerl-Registry/t/conf/extra.conf.in ModPerl-Registry/t/prefork.t

2005-05-10 Thread stas
Author: stas
Date: Tue May 10 19:17:16 2005
New Revision: 169560

URL: http://svn.apache.org/viewcvs?rev=169560view=rev
Log:
introduce ModPerl::RegistryPrefork and ModPerl::PerlRunPrefork, which
behave the same as ModPerl::Registry and ModPerl::PerlRun,
respectively, but chdir to the script's directory like mod_cgi
does. These two new handlers will refuse to load under threaded MPMs
where chdir can't be used as it will affect all running threads
+ tests

Added:
perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/PerlRunPrefork.pm   (with 
props)
perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryPrefork.pm   (with 
props)
perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/prefork.pl   (with props)
perl/modperl/trunk/ModPerl-Registry/t/prefork.t   (with props)
Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/ModPerl-Registry/t/conf/extra.conf.in

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=169560r1=169559r2=169560view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Tue May 10 19:17:16 2005
@@ -12,6 +12,12 @@
 
 =item 1.999_24-dev
 
+introduce ModPerl::RegistryPrefork and ModPerl::PerlRunPrefork, which
+behave the same as ModPerl::Registry and ModPerl::PerlRun,
+respectively, but chdir to the script's directory like mod_cgi
+does. These two new handlers will refuse to load under threaded MPMs
+where chdir can't be used as it will affect all running threads [Stas]
+
 ModPerl::RegistryCooker::chdir_file_normal() now chdirs to the current
 script's directory or the specified directory as an argument, as it
 was planned in first place. Therefore switch ModPerl::Registry and

Added: perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/PerlRunPrefork.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/PerlRunPrefork.pm?rev=169560view=auto
==
--- perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/PerlRunPrefork.pm (added)
+++ perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/PerlRunPrefork.pm Tue May 
10 19:17:16 2005
@@ -0,0 +1,24 @@
+package ModPerl::PerlRunPrefork;
+
+use strict;
+use warnings FATAL = 'all';
+
+our $VERSION = '0.01';
+
+use base qw(ModPerl::PerlRun);
+
+use Apache2::MPM ();
+
+die This package can't be used under threaded MPMs
+if Apache2::MPM-is_threaded;
+
+sub handler : method {
+my $class = (@_ = 2) ? shift : __PACKAGE__;
+my $r = shift;
+return $class-new($r)-default_handler();
+}
+
+*chdir_file = \ModPerl::RegistryCooker::chdir_file_normal;
+
+1;
+__END__

Propchange: perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/PerlRunPrefork.pm
--
svn:eol-style = native

Added: perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryPrefork.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryPrefork.pm?rev=169560view=auto
==
--- perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryPrefork.pm (added)
+++ perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryPrefork.pm Tue May 
10 19:17:16 2005
@@ -0,0 +1,24 @@
+package ModPerl::RegistryPrefork;
+
+use strict;
+use warnings FATAL = 'all';
+
+our $VERSION = '0.01';
+
+use base qw(ModPerl::Registry);
+
+use Apache2::MPM ();
+
+die This package can't be used under threaded MPMs
+if Apache2::MPM-is_threaded;
+
+sub handler : method {
+my $class = (@_ = 2) ? shift : __PACKAGE__;
+my $r = shift;
+return $class-new($r)-default_handler();
+}
+
+*chdir_file = \ModPerl::RegistryCooker::chdir_file_normal;
+
+1;
+__END__

Propchange: perl/modperl/trunk/ModPerl-Registry/lib/ModPerl/RegistryPrefork.pm
--
svn:eol-style = native

Added: perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/prefork.pl
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/prefork.pl?rev=169560view=auto
==
--- perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/prefork.pl (added)
+++ perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/prefork.pl Tue May 10 
19:17:16 2005
@@ -0,0 +1,19 @@
+#!perl -w
+
+# test that prefork runs from the directory the script lives in
+
+# All Modperl::*Prefork modules must chdir into the current dir, so we
+# should be able to read ourselves via a relative path
+
+print Content-type: text/plain\n\n;
+
+my $script = prefork.pl;
+if (open my $fh, $script) {
+print ok $script;
+}
+else {
+print prefork didn't chdir into the scripts directory?;
+print  The error was: $!;
+}
+
+

Propchange: perl/modperl/trunk/ModPerl-Registry/t/cgi-bin/prefork.pl

svn commit: r169572 - /perl/modperl/trunk/lib/ModPerl/BuildOptions.pm

2005-05-10 Thread stas
Author: stas
Date: Tue May 10 20:55:30 2005
New Revision: 169572

URL: http://svn.apache.org/viewcvs?rev=169572view=rev
Log:
terminate the error message by \n so it won't print an irrelevant: 
 at lib/ModPerl/BuildOptions.pm line 109, DATA line 23.
at the end of Usage string

Modified:
perl/modperl/trunk/lib/ModPerl/BuildOptions.pm

Modified: perl/modperl/trunk/lib/ModPerl/BuildOptions.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/BuildOptions.pm?rev=169572r1=169571r2=169572view=diff
==
--- perl/modperl/trunk/lib/ModPerl/BuildOptions.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/BuildOptions.pm Tue May 10 20:55:30 2005
@@ -106,7 +106,7 @@
 
 if (!$table-{$key} and $opts  UNKNOWN_FATAL) {
 my $usage = usage();
-die Unknown Option: $key\nUsage:\n$usage;
+die Unknown Option: $key\nUsage:\n$usage\n;
 }
 
 if ($key eq 'MP_APXS') {




svn commit: r169578 - /perl/modperl/trunk/lib/Apache2/Build.pm

2005-05-10 Thread stas
Author: stas
Date: Tue May 10 21:36:39 2005
New Revision: 169578

URL: http://svn.apache.org/viewcvs?rev=169578view=rev
Log:
use File::Copy instead of calling an external shell
Contributed by Nick *** [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=169578r1=169577r2=169578view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Tue May 10 21:36:39 2005
@@ -24,6 +24,7 @@
  catpath splitpath);
 use File::Basename;
 use ExtUtils::Embed ();
+use File::Copy ();
 
 use constant IS_MOD_PERL_BUILD = grep { -e $_/lib/mod_perl2.pm } qw(. ..);
 
@@ -1590,8 +1591,12 @@
 # when running make clean the real DynaLoader.a may get deleted.
 my $src = catfile $modperl_path, $self-{MP_LIBNAME}.a;
 my $dst = catfile $modperl_path, lib$self-{MP_LIBNAME}.a;
+# perl's link() on Cygwin seems to copy mod_perl.a to
+# libmod_perl.a, but at this stage mod_perl.a is still a dummy lib
+# and at the end we get nothing. whereas `ln -s` seems to create
+# something like the shortcut on windows and it works.
 qx{ln -s $src $dst} unless -e $dst;
-qx{cp $dyna_filepath $modperl_path/libDynaLoader.a};
+File::Copy::copy($dyna_filepath, $modperl_path/libDynaLoader.a);
 
 $modperl_static_libs_cygwin = join ' ',
 -L$modperl_path,




svn commit: r169579 - /perl/modperl/trunk/lib/Apache2/Build.pm

2005-05-10 Thread stas
Author: stas
Date: Tue May 10 21:51:16 2005
New Revision: 169579

URL: http://svn.apache.org/viewcvs?rev=169579view=rev
Log:
tidy up

Modified:
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=169579r1=169578r2=169579view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Tue May 10 21:51:16 2005
@@ -1005,14 +1005,14 @@
 # difference between where the apache headers are (to build
 # against) and where they will be installed (to install our
 # own headers alongside)
-# 
+#
 # ap_exp_includedir is where apache is going to install its
 # headers to
 sub ap_exp_includedir {
 my ($self) = @_;
-
+
 return $self-{ap_exp_includedir} if $self-{ap_exp_includedir};
-
+
 my $build_vars = File::Spec-catfile($self-{MP_AP_PREFIX}, 
  qw(build config_vars.mk));
 open my $vars, $build_vars or die Couldn't open $build_vars $!;
@@ -1023,7 +1023,7 @@
 last;
 }
 }
-
+
 $self-{ap_exp_includedir} = $ap_exp_includedir;
 }
 




svn commit: r169353 - in /perl/modperl/trunk: Changes lib/ModPerl/BuildOptions.pm

2005-05-09 Thread stas
Author: stas
Date: Mon May  9 13:31:14 2005
New Revision: 169353

URL: http://svn.apache.org/viewcvs?rev=169353view=rev
Log:
Show MP_APU_CONFIG as an argument to Makefile.PL in the Usage
menu.
Contributed by: Nick *** [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/ModPerl/BuildOptions.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=169353r1=169352r2=169353view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon May  9 13:31:14 2005
@@ -12,6 +12,9 @@
 
 =item 1.999_24-dev
 
+Show MP_APU_CONFIG as an argument to Makefile.PL in the Usage
+menu. [Nick *** [EMAIL PROTECTED]]
+
 Makefile.PL: fix the pre-rename mp2 install diagnostics code, to use
 the mp version of 1.999xx and not 1.999_xx, as the latter is
 unsuitable for numerical comparison [Stas].

Modified: perl/modperl/trunk/lib/ModPerl/BuildOptions.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/BuildOptions.pm?rev=169353r1=169352r2=169353view=diff
==
--- perl/modperl/trunk/lib/ModPerl/BuildOptions.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/BuildOptions.pm Mon May  9 13:31:14 2005
@@ -233,6 +233,7 @@
 AP_PREFIX  0Apache installation or source tree prefix
 AP_CONFIGURE   0Apache ./configure arguments
 APR_CONFIG 0Path to apr-config
+APU_CONFIG 0Path to apu-config
 XS_GLUE_DIR1Directories containing extension glue
 INCLUDE_DIR1Add directories to search for header files
 GENERATE_XS0Generate XS code based on httpd version




svn commit: r169355 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm

2005-05-09 Thread stas
Author: stas
Date: Mon May  9 13:38:47 2005
New Revision: 169355

URL: http://svn.apache.org/viewcvs?rev=169355view=rev
Log:
Fix a warning triggered by `ln` on Cygwin, when running perl
Makefile.PL for a second time without previously running make
clean.
Contributed by: Nick *** [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=169355r1=169354r2=169355view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon May  9 13:38:47 2005
@@ -12,6 +12,10 @@
 
 =item 1.999_24-dev
 
+Fix a warning triggered by `ln` on Cygwin, when running perl
+Makefile.PL for a second time without previously running make
+clean. [Nick *** [EMAIL PROTECTED]]
+
 When compiling a static mod_perl and
 MP_AP_CONFIGURE=--with-apr=/some/path argument is given, Apache will
 use the apr-config at the given path, but mod_perl was using the

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=169355r1=169354r2=169355view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Mon May  9 13:38:47 2005
@@ -1586,7 +1586,7 @@
 # when running make clean the real DynaLoader.a may get deleted.
 my $src = catfile $modperl_path, $self-{MP_LIBNAME}.a;
 my $dst = catfile $modperl_path, lib$self-{MP_LIBNAME}.a;
-qx{ln -s $src $dst};
+qx{ln -s $src $dst} unless -e $dst;
 qx{cp $dyna_filepath $modperl_path/libDynaLoader.a};
 
 $modperl_static_libs_cygwin = join ' ',




svn commit: r169382 - /perl/modperl/trunk/t/filter/TestFilter/out_str_ctx.pm

2005-05-09 Thread stas
Author: stas
Date: Mon May  9 16:45:51 2005
New Revision: 169382

URL: http://svn.apache.org/viewcvs?rev=169382view=rev
Log:
cleanup

Modified:
perl/modperl/trunk/t/filter/TestFilter/out_str_ctx.pm

Modified: perl/modperl/trunk/t/filter/TestFilter/out_str_ctx.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/TestFilter/out_str_ctx.pm?rev=169382r1=169381r2=169382view=diff
==
--- perl/modperl/trunk/t/filter/TestFilter/out_str_ctx.pm (original)
+++ perl/modperl/trunk/t/filter/TestFilter/out_str_ctx.pm Mon May  9 16:45:51 
2005
@@ -9,9 +9,6 @@
 use Apache2::RequestRec ();
 use Apache2::RequestIO ();
 
-use APR::Brigade ();
-use APR::Bucket ();
-
 use base qw(Apache2::Filter);
 
 use Apache2::Const -compile = qw(OK M_POST);




svn commit: r169395 - in /perl/modperl/trunk/t/filter: TestFilter/out_str_buffer.pm out_str_buffer.t

2005-05-09 Thread stas
Author: stas
Date: Mon May  9 19:08:49 2005
New Revision: 169395

URL: http://svn.apache.org/viewcvs?rev=169395view=rev
Log:
add a test which demonstrates the buffering of data, modifying its length and 
setting the correct C-L header before sending it out

Added:
perl/modperl/trunk/t/filter/TestFilter/out_str_buffer.pm   (with props)
perl/modperl/trunk/t/filter/out_str_buffer.t   (with props)

Added: perl/modperl/trunk/t/filter/TestFilter/out_str_buffer.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/TestFilter/out_str_buffer.pm?rev=169395view=auto
==
--- perl/modperl/trunk/t/filter/TestFilter/out_str_buffer.pm (added)
+++ perl/modperl/trunk/t/filter/TestFilter/out_str_buffer.pm Mon May  9 
19:08:49 2005
@@ -0,0 +1,98 @@
+package TestFilter::out_str_buffer;
+
+# in this test we want to buffer the data, modify the length of the
+# response, set the c-l header and make sure that the client sees the
+# right thing
+#
+# notice that a bucket brigades based filter must be used. The streaming
+# API lets FLUSH buckets through which causes an early flush of HTTP
+# response headers
+
+use strict;
+use warnings FATAL = 'all';
+
+use Apache2::RequestRec ();
+use Apache2::RequestIO ();
+
+use APR::Table ();
+use APR::Bucket ();
+use APR::Brigade ();
+
+use TestCommon::Utils ();
+
+use base qw(Apache2::Filter);
+
+use Apache2::Const -compile = qw(OK M_POST);
+use APR::Const -compile = ':common';
+
+sub flatten_bb {
+my ($bb) = shift;
+
+my $seen_eos = 0;
+
+my @data;
+for (my $b = $bb-first; $b; $b = $bb-next($b)) {
+$seen_eos++, last if $b-is_eos;
+$b-read(my $bdata);
+push @data, $bdata;
+}
+return (join('', @data), $seen_eos);
+}
+
+sub handler {
+my($filter, $bb) = @_;
+
+my $ctx = $filter-ctx;
+
+# no need to unset the C-L header, since this filter makes sure to
+# correct it before any headers go out.
+#unless ($ctx) {
+#$filter-r-headers_out-unset('Content-Length');
+#}
+
+my $data = exists $ctx-{data} ? $ctx-{data} : '';
+$ctx-{invoked}++;
+my($bdata, $seen_eos) = flatten_bb($bb);
+$bdata =~ s/-//g;
+$data .= $bdata if $bdata;
+
+if ($seen_eos) {
+my $len = length $data;
+$filter-r-headers_out-set('Content-Length', $len);
+$filter-print($data) if $data;
+}
+else {
+# store context for all but the last invocation
+$ctx-{data} = $data;
+$filter-ctx($ctx);
+}
+
+return Apache2::Const::OK;
+}
+
+sub response {
+my $r = shift;
+
+$r-content_type('text/plain');
+
+my $data = '';
+if ($r-method_number == Apache2::Const::M_POST) {
+$data = TestCommon::Utils::read_post($r);
+$r-headers_out-set('Content-Length' = length $data);
+}
+
+for my $chunk (split /0/, $data) {
+$r-print($chunk);
+$r-rflush; # so the filter reads a chunk at a time
+}
+
+return Apache2::Const::OK;
+}
+
+1;
+__DATA__
+
+SetHandler modperl
+PerlModule  TestFilter::out_str_buffer
+PerlResponseHandler TestFilter::out_str_buffer::response
+

Propchange: perl/modperl/trunk/t/filter/TestFilter/out_str_buffer.pm
--
svn:eol-style = native

Added: perl/modperl/trunk/t/filter/out_str_buffer.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/out_str_buffer.t?rev=169395view=auto
==
--- perl/modperl/trunk/t/filter/out_str_buffer.t (added)
+++ perl/modperl/trunk/t/filter/out_str_buffer.t Mon May  9 19:08:49 2005
@@ -0,0 +1,22 @@
+use strict;
+use warnings FATAL = 'all';
+
+use Apache::Test;
+use Apache::TestRequest;
+use Apache::TestUtil;
+
+plan tests = 2;
+
+my $sep = -0-;
+my $data = join $sep, aa .. zz;
+
+(my $expected = $data) =~ s/$sep//g;
+my $expected_len = length $expected;
+
+my $location = '/TestFilter__out_str_buffer';
+my $res = POST $location, content = $data;
+#t_debug $res-as_string;
+my $received_len = $res-header('Content-Length') || 0;
+ok t_cmp $received_len, $expected_len, Content-Length header;
+ok t_cmp $res-content, $expected, filtered data;
+

Propchange: perl/modperl/trunk/t/filter/out_str_buffer.t
--
svn:eol-style = native




svn commit: r168090 - in /perl/modperl/trunk: Changes RELEASE STATUS

2005-05-04 Thread stas
Author: stas
Date: Tue May  3 23:41:11 2005
New Revision: 168090

URL: http://svn.apache.org/viewcvs?rev=168090view=rev
Log:
start 1.999_25-dev cycle

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/RELEASE
perl/modperl/trunk/STATUS

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=168090r1=168089r2=168090view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Tue May  3 23:41:11 2005
@@ -10,6 +10,12 @@
 
 =over 3
 
+=item 1.999_24-dev
+
+
+
+
+
 =item 1.999_23 - May 3, 2005
 
 fix Apache2::Build::dynamic_link_MSWin32 to generate a new line after

Modified: perl/modperl/trunk/RELEASE
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/RELEASE?rev=168090r1=168089r2=168090view=diff
==
--- perl/modperl/trunk/RELEASE (original)
+++ perl/modperl/trunk/RELEASE Tue May  3 23:41:11 2005
@@ -1,7 +1,7 @@
 Instructions for mod_perl 2.0 Release Manager
 
 1. 'make dist' - to make sure nothing is missing from the manifest,
-   etc. Now test this generated package mod_perl-2.0.0-RC5.tar.gz (not
+   etc. Now test this generated package mod_perl-2.0.0-RC6.tar.gz (not
the current build) with as many
configurations as possible on as many platforms as possible,
unpacking the package each time afresh.
@@ -31,7 +31,7 @@
   a. edit ./Changes:
  - remove '-dev' 
  - add release date
- - temp: change VERSION in Makefile.PL to RC6 (while doing RC series)
+ - temp: change VERSION in Makefile.PL to RC7 (while doing RC series)
 
   b. check ./README and ./Makefile.PL
  - make sure supported httpd versions (dso  static) are current
@@ -52,29 +52,29 @@
 
   g. test the final package again at least once
 
-4. Release the package and update links (e.g. mod_perl-2.0.0-RC6.tar.gz)
+4. Release the package and update links (e.g. mod_perl-2.0.0-RC7.tar.gz)
 
   a. upload to www.apache.org:/www/perl.apache.org/dist/
 
-%  scp mod_perl-2.0.0-RC6.tar.gz perl.apache.org:/www/perl.apache.org/dist/
+%  scp mod_perl-2.0.0-RC7.tar.gz perl.apache.org:/www/perl.apache.org/dist/
 
   b. ssh to perl.apache.org, unpack the package, update symlinks to the
  tar ball and unpacked distro:
 
 % ssh perl.apache.org
 % cd /www/perl.apache.org/dist/
-% ln -sf mod_perl-2.0.0-RC6.tar.gz mod_perl-2.0-current.tar.gz
-% tar -xzvf mod_perl-2.0.0-RC6.tar.gz
+% ln -sf mod_perl-2.0.0-RC7.tar.gz mod_perl-2.0-current.tar.gz
+% tar -xzvf mod_perl-2.0.0-RC7.tar.gz
 % rm /www/perl.apache.org/dist/mod_perl-2.0-current
-% ln -sf  mod_perl-2.0.0-RC6 mod_perl-2.0-current
+% ln -sf  mod_perl-2.0.0-RC7 mod_perl-2.0-current
 
   c. archive older releases (keep current + one prior release)
 
-% mv /www/perl.apache.org/dist/mod_perl-2.0.0-RC4.tar.gz \
+% mv /www/perl.apache.org/dist/mod_perl-2.0.0-RC5.tar.gz \
  /www/perl.apache.org/dist/old
-% mv /www/perl.apache.org/dist/mod_perl-2.0.0-RC4.tar.gz.asc \
+% mv /www/perl.apache.org/dist/mod_perl-2.0.0-RC5.tar.gz.asc \
  /www/perl.apache.org/dist/old
-% rm -rf /www/perl.apache.org/dist/mod_perl-2.0.0-RC4
+% rm -rf /www/perl.apache.org/dist/mod_perl-2.0.0-RC5
 
   d. update the version and release date
  modperl-docs/src/download/index_top.html and commit. It'll be
@@ -92,27 +92,27 @@
 
   a. sign your local copy of the tarball:
 
-% gpg --detach-sign --armor mod_perl-2.0.0-RC6.tar.gz
+% gpg --detach-sign --armor mod_perl-2.0.0-RC7.tar.gz
 
-% pgps -b --armor mod_perl-2.0.0-RC6.tar.gz
+% pgps -b --armor mod_perl-2.0.0-RC7.tar.gz
 
   b. upload the generated sig file to www.apache.org:
 
-% scp mod_perl-2.0.0-RC6.tar.gz.asc 
perl.apache.org:/www/perl.apache.org/dist/
+% scp mod_perl-2.0.0-RC7.tar.gz.asc 
perl.apache.org:/www/perl.apache.org/dist/
 % ssh www.apache.org
 % cd /www/perl.apache.org/dist/
-% chmod 0664 mod_perl-2.0.0-RC6.tar.gz.asc
-% ln -sf mod_perl-2.0.0-RC6.tar.gz.asc mod_perl-2.0-current.tar.gz.asc
+% chmod 0664 mod_perl-2.0.0-RC7.tar.gz.asc
+% ln -sf mod_perl-2.0.0-RC7.tar.gz.asc mod_perl-2.0-current.tar.gz.asc
 
   c. ask one of the other developers to double check the signature file
  and tarball: download both files and verify the signature:
 
-http://perl.apache.org/dist/mod_perl-2.0.0-RC6.tar.gz.asc
-http://perl.apache.org/dist/mod_perl-2.0.0-RC6.tar.gz
+http://perl.apache.org/dist/mod_perl-2.0.0-RC7.tar.gz.asc
+http://perl.apache.org/dist/mod_perl-2.0.0-RC7.tar.gz
 
-% gpg --verify mod_perl-2.0.0-RC6.tar.gz.asc
+% gpg --verify mod_perl-2.0.0-RC7.tar.gz.asc
 
-% pgpv mod_perl-2.0.0-RC6.tar.gz.asc
+% pgpv mod_perl-2.0.0-RC7.tar.gz.asc
 
   d. make sure that the files you just created are group rw so
  all the dist admins can make changes:
@@ -126,10

svn commit: r168091 - /perl/modperl/trunk/lib/mod_perl2.pm

2005-05-04 Thread stas
Author: stas
Date: Tue May  3 23:43:39 2005
New Revision: 168091

URL: http://svn.apache.org/viewcvs?rev=168091view=rev
Log:
start 1.999_24-dev cycle

Modified:
perl/modperl/trunk/lib/mod_perl2.pm

Modified: perl/modperl/trunk/lib/mod_perl2.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/mod_perl2.pm?rev=168091r1=168090r2=168091view=diff
==
--- perl/modperl/trunk/lib/mod_perl2.pm (original)
+++ perl/modperl/trunk/lib/mod_perl2.pm Tue May  3 23:43:39 2005
@@ -18,7 +18,7 @@
 use strict;
 
 BEGIN {
-our $VERSION = 1.999023;
+our $VERSION = 1.999024;
 our $VERSION_TRIPLET;
 
 if ($VERSION =~ /(\d+)\.(\d\d\d)(\d+)/) {




svn commit: r168093 - /perl/modperl/trunk/RELEASE

2005-05-04 Thread stas
Author: stas
Date: Tue May  3 23:45:40 2005
New Revision: 168093

URL: http://svn.apache.org/viewcvs?rev=168093view=rev
Log:
make it one version down, so after reload of the file a releaser gets the right 
version (still the current one)

Modified:
perl/modperl/trunk/RELEASE

Modified: perl/modperl/trunk/RELEASE
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/RELEASE?rev=168093r1=168092r2=168093view=diff
==
--- perl/modperl/trunk/RELEASE (original)
+++ perl/modperl/trunk/RELEASE Tue May  3 23:45:40 2005
@@ -174,6 +174,6 @@
 
   e. commit the changed files
 
- % svn ci -m start 1.999_25-dev cycle Changes lib/mod_perl2.pm \
+ % svn ci -m start 1.999_24-dev cycle Changes lib/mod_perl2.pm \
STATUS RELEASE
 




svn commit: r168049 - /perl/modperl/trunk/README

2005-05-03 Thread stas
Author: stas
Date: Tue May  3 19:26:03 2005
New Revision: 168049

URL: http://svn.apache.org/viewcvs?rev=168049view=rev
Log:
2.0.54 is out

Modified:
perl/modperl/trunk/README

Modified: perl/modperl/trunk/README
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/README?rev=168049r1=168048r2=168049view=diff
==
--- perl/modperl/trunk/README (original)
+++ perl/modperl/trunk/README Tue May  3 19:26:03 2005
@@ -3,8 +3,8 @@
 *** Prerequisites ***
 
 Apache:
-  Dynamic mod_perl (DSO):Apache 2.0.47 - 2.0.53.
-  Static mod_perl:   Apache 2.0.51 - 2.0.53.
+  Dynamic mod_perl (DSO):Apache 2.0.47 - 2.0.54.
+  Static mod_perl:   Apache 2.0.51 - 2.0.54.
 
   Newer Apache versions may work with this version of mod_perl.  If
   not, the svn version likely will, which can be obtained from:




svn commit: r168055 - in /perl/modperl/trunk: Changes Makefile.PL

2005-05-03 Thread stas
Author: stas
Date: Tue May  3 19:44:40 2005
New Revision: 168055

URL: http://svn.apache.org/viewcvs?rev=168055view=rev
Log:
RC6 release

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/Makefile.PL

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=168055r1=168054r2=168055view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Tue May  3 19:44:40 2005
@@ -10,7 +10,7 @@
 
 =over 3
 
-=item 1.999_23-dev
+=item 1.999_23 - May 3, 2005
 
 fix Apache2::Build::dynamic_link_MSWin32 to generate a new line after
 dynamic_link code in Makefile [Nick *** [EMAIL PROTECTED]]

Modified: perl/modperl/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Makefile.PL?rev=168055r1=168054r2=168055view=diff
==
--- perl/modperl/trunk/Makefile.PL (original)
+++ perl/modperl/trunk/Makefile.PL Tue May  3 19:44:40 2005
@@ -67,7 +67,7 @@
 
 ModPerl::BuildMM::WriteMakefile(
 NAME  = 'mod_perl2',
-VERSION   = '2.0.0-RC5',
+VERSION   = '2.0.0-RC6',
 DISTNAME  = 'mod_perl',
 NO_META   = 1,
 ABSTRACT_FROM = 'lib/mod_perl2.pm',




svn commit: r168056 - in /perl/modperl/tags/2_0_0_RC6: ./ Changes Makefile.PL README RELEASE build/make_etags t/conf/extra.conf.in

2005-05-03 Thread stas
Author: stas
Date: Tue May  3 19:45:13 2005
New Revision: 168056

URL: http://svn.apache.org/viewcvs?rev=168056view=rev
Log:
RC6

Added:
perl/modperl/tags/2_0_0_RC6/
  - copied from r168044, perl/modperl/trunk/
perl/modperl/tags/2_0_0_RC6/Changes
  - copied unchanged from r168055, perl/modperl/trunk/Changes
perl/modperl/tags/2_0_0_RC6/Makefile.PL
  - copied unchanged from r168055, perl/modperl/trunk/Makefile.PL
perl/modperl/tags/2_0_0_RC6/README
  - copied unchanged from r168049, perl/modperl/trunk/README
perl/modperl/tags/2_0_0_RC6/RELEASE
  - copied unchanged from r168054, perl/modperl/trunk/RELEASE
Modified:
perl/modperl/tags/2_0_0_RC6/build/make_etags
perl/modperl/tags/2_0_0_RC6/t/conf/extra.conf.in

Modified: perl/modperl/tags/2_0_0_RC6/build/make_etags
URL: 
http://svn.apache.org/viewcvs/perl/modperl/tags/2_0_0_RC6/build/make_etags?rev=168056r1=168044r2=168056view=diff
==
--- perl/modperl/tags/2_0_0_RC6/build/make_etags (original)
+++ perl/modperl/tags/2_0_0_RC6/build/make_etags Tue May  3 19:45:13 2005
@@ -8,10 +8,10 @@
 
 #e.g. symlink to $HOME/perl/perl-current
 #XXX: perl has its own (more robust) TAGS generator: emacs/ptags
-perl_src=$root/perl/
+perl_src=$root/perl
 #XXX: apache has its own: build/MakeEtags
-apache_src=$root/httpd-2.0/
-modperl_src=$root/modperl-2.0/src/
+apache_src=$root/httpd-2.0
+modperl_src=$root/modperl-2.0/src
 xs_src=$root/modperl-2.0/xs
 
 cd $root/modperl-2.0
@@ -24,4 +24,4 @@
 
 (cd src/modules/perl  etags `cat etag_files`)
 
-rm -f src/modules/perl/etag_files
+#rm -f src/modules/perl/etag_files

Modified: perl/modperl/tags/2_0_0_RC6/t/conf/extra.conf.in
URL: 
http://svn.apache.org/viewcvs/perl/modperl/tags/2_0_0_RC6/t/conf/extra.conf.in?rev=168056r1=168044r2=168056view=diff
==
--- perl/modperl/tags/2_0_0_RC6/t/conf/extra.conf.in (original)
+++ perl/modperl/tags/2_0_0_RC6/t/conf/extra.conf.in Tue May  3 19:45:13 2005
@@ -73,15 +73,15 @@
 # /sandbox-friendly
 
 Location /status/perl
-#PerlSetVar StatusOptionsAll On
-#PerlSetVar StatusDumper On
-#PerlSetVar StatusPeek On
-#PerlSetVar StatusLexInfo On
-#PerlSetVar StatusDeparse On
-#PerlSetVar StatusDeparseOptions -p -sC
-#PerlSetVar StatusTerse On
-#PerlSetVar StatusTerseSize On
-#PerlSetVar StatusTerseSizeMainSummary On
+PerlSetVar StatusOptionsAll On
+PerlSetVar StatusDumper On
+PerlSetVar StatusPeek On
+PerlSetVar StatusLexInfo On
+PerlSetVar StatusDeparse On
+PerlSetVar StatusDeparseOptions -p -sC
+PerlSetVar StatusTerse On
+PerlSetVar StatusTerseSize On
+PerlSetVar StatusTerseSizeMainSummary On
 SetHandler modperl
 PerlResponseHandler Apache2::Status
 /Location




svn commit: r165380 - /perl/modperl/branches/clone-skip-unstable/t/perl/ithreads_cloning.t

2005-04-30 Thread stas
Author: stas
Date: Fri Apr 29 23:16:48 2005
New Revision: 165380

URL: http://svn.apache.org/viewcvs?rev=165380view=rev
Log:
remove autogenerated file

Removed:
perl/modperl/branches/clone-skip-unstable/t/perl/ithreads_cloning.t



svn commit: r165384 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm

2005-04-30 Thread stas
Author: stas
Date: Sat Apr 30 00:08:25 2005
New Revision: 165384

URL: http://svn.apache.org/viewcvs?rev=165384view=rev
Log:
fix a warning in Apache2::Build::build_config() when building
with MP_STATIC_EXTS=1 
Contributed by: Nick *** [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=165384r1=165383r2=165384view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Sat Apr 30 00:08:25 2005
@@ -12,6 +12,9 @@
 
 =item 1.999_23-dev
 
+fix a warning in Apache2::Build::build_config() when building
+with MP_STATIC_EXTS=1 [Nick *** [EMAIL PROTECTED]]
+
 improving DSO support on cygwin. The problem with cygwin is that it
 behaves like windows (it's a posix layer over windows after
 all). That's why we need to supply all symbols during linking time

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=165384r1=165383r2=165384view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Sat Apr 30 00:08:25 2005
@@ -783,7 +783,7 @@
 my $self = shift;
 my $bpm_mtime = 0;
 
-$bpm_mtime = (stat $INC{$bpm})[9] if $INC{$bpm};
+$bpm_mtime = (stat _)[9] if $INC{$bpm}  -e $INC{$bpm};
 
 if (-e lib/$bpm and (stat _)[9]  $bpm_mtime) {
 #reload if Makefile.PL has regenerated




svn commit: r165385 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm

2005-04-30 Thread stas
Author: stas
Date: Sat Apr 30 00:11:05 2005
New Revision: 165385

URL: http://svn.apache.org/viewcvs?rev=165385view=rev
Log:
fix Apache2::Build::dynamic_link_MSWin32 to generate a new line after
dynamic_link code in Makefile 
contributed by: Nick *** [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=165385r1=165384r2=165385view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Sat Apr 30 00:11:05 2005
@@ -12,6 +12,9 @@
 
 =item 1.999_23-dev
 
+fix Apache2::Build::dynamic_link_MSWin32 to generate a new line after
+dynamic_link code in Makefile [Nick *** [EMAIL PROTECTED]]
+
 fix a warning in Apache2::Build::build_config() when building
 with MP_STATIC_EXTS=1 [Nick *** [EMAIL PROTECTED]]
 

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=165385r1=165384r2=165385view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Sat Apr 30 00:11:05 2005
@@ -1505,7 +1505,7 @@
 return $self-dynamic_link_header_default .
 \t$defs .
 ($symbols ? ' \\' . \n\t-pdb:$symbols : '') .
-' -out:$@';
+ -out:[EMAIL PROTECTED];
 }
 
 sub dynamic_link_aix {




svn commit: r165141 - in /perl/modperl/trunk: Changes lib/Apache2/Build.pm

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 07:05:46 2005
New Revision: 165141

URL: http://svn.apache.org/viewcvs?rev=165141view=rev
Log:
improving DSO support on cygwin. The problem with cygwin is that it
behaves like windows (it's a posix layer over windows after
all). That's why we need to supply all symbols during linking time
just like on win32, by adding -lapr-0 -laprutil-0 and -lhttpd. On
windows, Apache supplies all the three libraries and it's easy to
link, but on cygwin apache doesn't play nice and doesn't supply
libhttpd. 
Submitted by: Nick *** [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Build.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=165141r1=165140r2=165141view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Thu Apr 28 07:05:46 2005
@@ -12,6 +12,15 @@
 
 =item 1.999_23-dev
 
+improving DSO support on cygwin. The problem with cygwin is that it
+behaves like windows (it's a posix layer over windows after
+all). That's why we need to supply all symbols during linking time
+just like on win32, by adding -lapr-0 -laprutil-0 and -lhttpd. On
+windows, Apache supplies all the three libraries and it's easy to
+link, but on cygwin apache doesn't play nice and doesn't supply
+libhttpd. This change adds libapr and libaprutil. [Nick ***
+[EMAIL PROTECTED]]
+
 improve the diagnostics when detecting mp2  1.999022, tell the user
 which files and/or dirs need to be removed [Stas]
 

Modified: perl/modperl/trunk/lib/Apache2/Build.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Build.pm?rev=165141r1=165140r2=165141view=diff
==
--- perl/modperl/trunk/lib/Apache2/Build.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Build.pm Thu Apr 28 07:05:46 2005
@@ -40,7 +40,7 @@
 use constant REQUIRE_ITHREADS = grep { $^O eq $_ } qw(MSWin32);
 use constant PERL_HAS_ITHREADS =
 $Config{useithreads}  ($Config{useithreads} eq 'define');
-use constant BUILD_APREXT = WIN32();
+use constant BUILD_APREXT = WIN32() || CYGWIN();
 
 use ModPerl::Code ();
 use ModPerl::BuildOptions ();
@@ -464,6 +464,10 @@
 $ldopts .= $self-gtop_ldopts;
 }
 
+if (CYGWIN  $self-is_dynamic) {
+$ldopts .= join ' ', '', $self-apru_link_flags;
+}
+
 $config-{ldflags} = $ldflags; #reset
 
 # on Irix mod_perl.so needs to see the libperl.so symbols, which
@@ -1050,7 +1054,9 @@
 
 return @apru_link_flags if @apru_link_flags;
 
-for ($self-apr_config_path, $self-apu_config_path) {
+# first use apu_config_path and then apr_config_path in order to
+# resolve the symbols right during linking
+for ($self-apu_config_path, $self-apr_config_path) {
 if (my $link = $_  -x $_  qx{$_ --link-ld --libs}) {
 chomp $link;
 if ($self-httpd_is_source_tree) {
@@ -1538,6 +1544,11 @@
 $self-{cwd}/src/modules/perl/$self-{MP_LIBNAME}.lib;
 }
 
+sub modperl_libs_cygwin {
+ my $self = shift;
+ -L$self-{cwd}/src/modules/perl -l$self-{MP_LIBNAME};
+}
+
 sub modperl_libs {
 my $self = shift;
 my $libs = \{modperl_libs_$^O};
@@ -1566,6 +1577,20 @@
 return qq{ -L$dir -l$lib };
 }
 
+sub mp_apr_lib_cygwin {
+my $self = shift;
+my ($dir, $lib) = $self-mp_apr_blib();
+$lib =~ s[^lib(\w+)$Config{lib_ext}$][$1];
+my $libs = -L$dir -l$lib;
+
+# This is ugly, but is the only way to prevent the undefined
+# symbols error
+$libs .= join ' ', '', $self-apru_link_flags,
+'-L' . catdir($self-perl_config('archlibexp'), 'CORE'), '-lperl';
+
+$libs;
+}
+
 # linking used for the aprext lib used to build APR/APR::*
 sub mp_apr_lib {
 my $self = shift;
@@ -1798,6 +1823,17 @@
 my $self = shift;
 my $flags = $self-otherldflags_default;
 $flags .= ' -pdb:$(INST_ARCHAUTODIR)\$(BASEEXT).pdb' if $self-{MP_DEBUG};
+$flags;
+}
+
+sub otherldflags_cygwin {
+my $self = shift;
+my $flags = $self-otherldflags_default;
+
+unless ($self-{MP_STATIC_EXTS}) {
+$flags .= join ' ', $self-apru_link_flags;
+}
+
 $flags;
 }
 




svn commit: r165170 - in /perl/modperl/trunk/t: protocol/TestProtocol/echo_timeout.pm response/TestError/runtime.pm

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 10:50:38 2005
New Revision: 165170

URL: http://svn.apache.org/viewcvs?rev=165170view=rev
Log:
fix the test to use the right error checking

Modified:
perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm
perl/modperl/trunk/t/response/TestError/runtime.pm

Modified: perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm?rev=165170r1=165169r2=165170view=diff
==
--- perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm (original)
+++ perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm Thu Apr 28 
10:50:38 2005
@@ -10,9 +10,10 @@
 
 use Apache2::Connection ();
 use APR::Socket ();
+use APR::Status ();
 
 use Apache2::Const -compile = 'OK';
-use APR::Const-compile = qw(TIMEUP SO_NONBLOCK);
+use APR::Const -compile = qw(SO_NONBLOCK);
 
 use constant BUFF_LEN = 1024;
 
@@ -32,7 +33,7 @@
 my $buff;
 my $rlen = eval { $socket-recv($buff, BUFF_LEN) };
 if ($@) {
-die timed out, giving up: $@ if $@ == APR::Const::TIMEUP;
+die timed out, giving up: $@ if APR::Status::is_EAGAIN($@);
 die $@;
 }
 
@@ -40,7 +41,7 @@
 
 my $wlen = eval { $socket-send($buff) };
 if ($@) {
-die timed out, giving up: $@ if $@ == APR::Const::TIMEUP;
+die timed out, giving up: $@ if APR::Status::is_EAGAIN($@);
 die $@;
 }
 }

Modified: perl/modperl/trunk/t/response/TestError/runtime.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestError/runtime.pm?rev=165170r1=165169r2=165170view=diff
==
--- perl/modperl/trunk/t/response/TestError/runtime.pm (original)
+++ perl/modperl/trunk/t/response/TestError/runtime.pm Thu Apr 28 10:50:38 2005
@@ -7,12 +7,12 @@
 use Apache2::RequestIO ();
 use Apache2::Connection ();
 use APR::Socket ();
+use APR::Status ();
 
 use Apache::TestUtil;
 
 use Apache2::Const -compile = qw(OK);
-use APR::Const-compile = qw(EACCES EAGAIN);
-use APR::Status ();
+use APR::Const -compile = qw(EACCES);
 
 use constant SIZE = 2048;
 
@@ -43,7 +43,7 @@
 die the exception should have been an APR::Error object
 unless ref $@ eq 'APR::Error';
 
-# ==  != (expecting APR::Const::EAGAIN error)
+# ==  != (expecting an EAGAIN error)
 die APR::Status is broken   unless APR::Status::is_EAGAIN($@);
 die '==' overload is broken unless $@ == $@;
 die '!=' overload is broken unless $@ != APR::Const::EACCES;




svn commit: r165203 - /perl/modperl/tags/pre-clone-skip

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 14:19:19 2005
New Revision: 165203

URL: http://svn.apache.org/viewcvs?rev=165203view=rev
Log:
tag before branching for CLONE_SKIP support

Added:
perl/modperl/tags/pre-clone-skip/
  - copied from r165202, perl/modperl/trunk/



svn commit: r165204 - /perl/modperl/branches/clone-skip-unstable

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 14:19:28 2005
New Revision: 165204

URL: http://svn.apache.org/viewcvs?rev=165204view=rev
Log:
branching to provide CLONE_SKIP support

Added:
perl/modperl/branches/clone-skip-unstable/
  - copied from r165203, perl/modperl/trunk/



svn commit: r165210 - /perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 15:00:06 2005
New Revision: 165210

URL: http://svn.apache.org/viewcvs?rev=165210view=rev
Log:
revert: it was a correct timeout error checking

Modified:
perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm

Modified: perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm?rev=165210r1=165209r2=165210view=diff
==
--- perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm (original)
+++ perl/modperl/trunk/t/protocol/TestProtocol/echo_timeout.pm Thu Apr 28 
15:00:06 2005
@@ -10,10 +10,9 @@
 
 use Apache2::Connection ();
 use APR::Socket ();
-use APR::Status ();
 
 use Apache2::Const -compile = 'OK';
-use APR::Const -compile = qw(SO_NONBLOCK);
+use APR::Const -compile = qw(TIMEUP SO_NONBLOCK);
 
 use constant BUFF_LEN = 1024;
 
@@ -33,7 +32,7 @@
 my $buff;
 my $rlen = eval { $socket-recv($buff, BUFF_LEN) };
 if ($@) {
-die timed out, giving up: $@ if APR::Status::is_EAGAIN($@);
+die timed out, giving up: $@ if $@ == APR::Const::TIMEUP;
 die $@;
 }
 
@@ -41,7 +40,7 @@
 
 my $wlen = eval { $socket-send($buff) };
 if ($@) {
-die timed out, giving up: $@ if APR::Status::is_EAGAIN($@);
+die timed out, giving up: $@ if $@ == APR::Const::TIMEUP;
 die $@;
 }
 }




svn commit: r165213 - in /perl/modperl/branches/clone-skip-unstable: lib/ModPerl/ src/modules/perl/ t/apr-ext/ t/conf/ t/lib/TestAPRlib/ t/lib/TestCommon/ t/perl/ t/response/TestPerl/ todo/ xs/ xs/APR/Bucket/ xs/APR/Pool/ xs/APR/Table/ xs/maps/

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 15:18:42 2005
New Revision: 165213

URL: http://svn.apache.org/viewcvs?rev=165213view=rev
Log:
working to support CLONE_SKIP

Added:
perl/modperl/branches/clone-skip-unstable/t/perl/ithreads_cloning.t   (with 
props)

perl/modperl/branches/clone-skip-unstable/t/response/TestPerl/ithreads_cloning.pm
   (with props)
Modified:
perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm

perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c

perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_util.c
perl/modperl/branches/clone-skip-unstable/t/apr-ext/pool.t
perl/modperl/branches/clone-skip-unstable/t/apr-ext/table.t
perl/modperl/branches/clone-skip-unstable/t/conf/modperl_extra.pl
perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/pool.pm
perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/table.pm
perl/modperl/branches/clone-skip-unstable/t/lib/TestCommon/Utils.pm
perl/modperl/branches/clone-skip-unstable/t/perl/ithreads.t
perl/modperl/branches/clone-skip-unstable/todo/release
perl/modperl/branches/clone-skip-unstable/xs/APR/Bucket/APR__Bucket.h
perl/modperl/branches/clone-skip-unstable/xs/APR/Pool/APR__Pool.h
perl/modperl/branches/clone-skip-unstable/xs/APR/Table/APR__Table.h
perl/modperl/branches/clone-skip-unstable/xs/maps/apr_functions.map
perl/modperl/branches/clone-skip-unstable/xs/typemap

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm?rev=165213r1=165212r2=165213view=diff
==
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm Thu Apr 28 
15:18:42 2005
@@ -499,8 +499,15 @@
 $define = mp_xs_${ptype}_2obj;
 
 $code .= EOF;
-#define $define(ptr) \\
-sv_setref_pv(sv_newmortal(), $class, (void*)ptr)
+MP_INLINE SV *$define(pTHX_ void *ptr);
+MP_INLINE SV *$define(pTHX_ void *ptr)
+{
+SV *rv = sv_setref_pv(sv_newmortal(), $class, ptr);
+if (ptr) {
+MP_CLONE_INSERT_OBJ($class, rv);
+}
+return rv;
+}
 
 EOF
 

Modified: 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c?rev=165213r1=165212r2=165213view=diff
==
--- 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c
 (original)
+++ 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c
 Thu Apr 28 15:18:42 2005
@@ -64,8 +64,9 @@
 SV *hv = (SV*)newHV();
 SV *rsv = sv_newmortal();
 
-sv_setref_pv(rsv, classname, p);
-
+SV *rv = sv_setref_pv(rsv, classname, p);
+MP_CLONE_INSERT_OBJ(APR::Table, rv);
+
 /* Prefetch magic requires perl 5.8 */
 #if ((PERL_REVISION == 5)  (PERL_VERSION = 8))
 

Modified: 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h?rev=165213r1=165212r2=165213view=diff
==
--- 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
 (original)
+++ 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
 Thu Apr 28 15:18:42 2005
@@ -97,5 +97,128 @@
 
 SV *modperl_perl_gensym(pTHX_ char *pack);
 
+/*** ithreads enabled perl CLONE support ***/
+#define MP_CLONE_DEBUG 1
+
+#define MP_CLONE_HASH_NAME ::CLONE_objects
+#define MP_CLONE_HASH_NAME1 CLONE_objects
+#define MP_CLONE_HASH_LEN1 13
+
+/* some classes like APR::Table get the key in a different way and
+ * therefore should redefine this define */
+#define MP_CLONE_KEY_COMMON(obj) SvIVX(SvRV(obj))
+
+#define MP_CLONE_GET_HV(namespace)  \
+get_hv(Perl_form(aTHX_ %s::%s, namespace, MP_CLONE_HASH_NAME), TRUE);
+
+#if MP_CLONE_DEBUG
+
+#define MP_CLONE_DEBUG_INSERT_KEY(namespace, obj)   \
+Perl_warn(aTHX_ %s %p: insert %s, %p = %p,   \
+  namespace, aTHX_ SvPV_nolen(sv_key), obj, SvRV(obj));
+
+#define MP_CLONE_DEBUG_HOLLOW_KEY(namespace)\
+Perl_warn(aTHX_ %s %p: hollow %s, namespace,  \
+  aTHX_ SvPVX(hv_iterkeysv(he)));
+
+#define MP_CLONE_DEBUG_DELETE_KEY(namespace)\
+Perl_warn(aTHX_ %s %p: delete %s, namespace, aTHX_ SvPVX(sv_key));
+
+#define

svn commit: r165214 - in /perl/modperl/branches/clone-skip-unstable: lib/ModPerl/ src/modules/perl/ t/apr-ext/ t/conf/ t/lib/TestAPRlib/ t/lib/TestCommon/ t/perl/ t/response/TestPerl/ todo/ xs/ xs/APR/Bucket/ xs/APR/Pool/ xs/APR/Table/ xs/maps/

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 15:22:22 2005
New Revision: 165214

URL: http://svn.apache.org/viewcvs?rev=165214view=rev
Log:
revert: wrong branch :(

Modified:
perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm

perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c

perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_util.c
perl/modperl/branches/clone-skip-unstable/t/apr-ext/pool.t
perl/modperl/branches/clone-skip-unstable/t/apr-ext/table.t
perl/modperl/branches/clone-skip-unstable/t/conf/modperl_extra.pl
perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/pool.pm
perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/table.pm
perl/modperl/branches/clone-skip-unstable/t/lib/TestCommon/Utils.pm
perl/modperl/branches/clone-skip-unstable/t/perl/ithreads.t
perl/modperl/branches/clone-skip-unstable/t/perl/ithreads_cloning.t

perl/modperl/branches/clone-skip-unstable/t/response/TestPerl/ithreads_cloning.pm
perl/modperl/branches/clone-skip-unstable/todo/release
perl/modperl/branches/clone-skip-unstable/xs/APR/Bucket/APR__Bucket.h
perl/modperl/branches/clone-skip-unstable/xs/APR/Pool/APR__Pool.h
perl/modperl/branches/clone-skip-unstable/xs/APR/Table/APR__Table.h
perl/modperl/branches/clone-skip-unstable/xs/maps/apr_functions.map
perl/modperl/branches/clone-skip-unstable/xs/typemap

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm?rev=165214r1=165213r2=165214view=diff
==
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/TypeMap.pm Thu Apr 28 
15:22:22 2005
@@ -499,15 +499,8 @@
 $define = mp_xs_${ptype}_2obj;
 
 $code .= EOF;
-MP_INLINE SV *$define(pTHX_ void *ptr);
-MP_INLINE SV *$define(pTHX_ void *ptr)
-{
-SV *rv = sv_setref_pv(sv_newmortal(), $class, ptr);
-if (ptr) {
-MP_CLONE_INSERT_OBJ($class, rv);
-}
-return rv;
-}
+#define $define(ptr) \\
+sv_setref_pv(sv_newmortal(), $class, (void*)ptr)
 
 EOF
 

Modified: 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c?rev=165214r1=165213r2=165214view=diff
==
--- 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c
 (original)
+++ 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.c
 Thu Apr 28 15:22:22 2005
@@ -64,9 +64,8 @@
 SV *hv = (SV*)newHV();
 SV *rsv = sv_newmortal();
 
-SV *rv = sv_setref_pv(rsv, classname, p);
-MP_CLONE_INSERT_OBJ(APR::Table, rv);
-
+sv_setref_pv(rsv, classname, p);
+
 /* Prefetch magic requires perl 5.8 */
 #if ((PERL_REVISION == 5)  (PERL_VERSION = 8))
 

Modified: 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h?rev=165214r1=165213r2=165214view=diff
==
--- 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
 (original)
+++ 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_common_util.h
 Thu Apr 28 15:22:22 2005
@@ -97,128 +97,5 @@
 
 SV *modperl_perl_gensym(pTHX_ char *pack);
 
-/*** ithreads enabled perl CLONE support ***/
-#define MP_CLONE_DEBUG 1
-
-#define MP_CLONE_HASH_NAME ::CLONE_objects
-#define MP_CLONE_HASH_NAME1 CLONE_objects
-#define MP_CLONE_HASH_LEN1 13
-
-/* some classes like APR::Table get the key in a different way and
- * therefore should redefine this define */
-#define MP_CLONE_KEY_COMMON(obj) SvIVX(SvRV(obj))
-
-#define MP_CLONE_GET_HV(namespace)  \
-get_hv(Perl_form(aTHX_ %s::%s, namespace, MP_CLONE_HASH_NAME), TRUE);
-
-#if MP_CLONE_DEBUG
-
-#define MP_CLONE_DEBUG_INSERT_KEY(namespace, obj)   \
-Perl_warn(aTHX_ %s %p: insert %s, %p = %p,   \
-  namespace, aTHX_ SvPV_nolen(sv_key), obj, SvRV(obj));
-
-#define MP_CLONE_DEBUG_HOLLOW_KEY(namespace)\
-Perl_warn(aTHX_ %s %p: hollow %s, namespace,  \
-  aTHX_ SvPVX(hv_iterkeysv(he)));
-
-#define MP_CLONE_DEBUG_DELETE_KEY(namespace)\
-Perl_warn(aTHX_ %s %p: delete %s, namespace, aTHX_ SvPVX(sv_key));
-
-#define MP_CLONE_DEBUG_CLONE(namespace

svn commit: r165215 - in /perl/modperl/branches/clone-skip-unstable: ModPerl-Registry/t/ lib/ModPerl/ src/modules/perl/ t/apr-ext/ t/conf/ t/lib/TestAPRlib/ t/lib/TestCommon/ t/perl/ t/response/TestAPR/ t/response/TestDirective/ t/response/TestPerl/ xs/APR/APR/ xs/APR/Const/ xs/APR/PerlIO/ xs/Apache2/Const/ xs/ModPerl/Const/

2005-04-28 Thread stas
Author: stas
Date: Thu Apr 28 15:24:43 2005
New Revision: 165215

URL: http://svn.apache.org/viewcvs?rev=165215view=rev
Log:
merge the right branch: CLONE_SKIP support

Modified:
perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/ithreads.t
perl/modperl/branches/clone-skip-unstable/lib/ModPerl/WrapXS.pm

perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_io_apache.c
perl/modperl/branches/clone-skip-unstable/t/apr-ext/pool.t
perl/modperl/branches/clone-skip-unstable/t/apr-ext/table.t
perl/modperl/branches/clone-skip-unstable/t/conf/modperl_extra.pl
perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/pool.pm
perl/modperl/branches/clone-skip-unstable/t/lib/TestAPRlib/table.pm
perl/modperl/branches/clone-skip-unstable/t/lib/TestCommon/Utils.pm
perl/modperl/branches/clone-skip-unstable/t/perl/ithreads_cloning.t
perl/modperl/branches/clone-skip-unstable/t/response/TestAPR/pool.pm
perl/modperl/branches/clone-skip-unstable/t/response/TestAPR/table.pm

perl/modperl/branches/clone-skip-unstable/t/response/TestDirective/cmdparms.pm

perl/modperl/branches/clone-skip-unstable/t/response/TestPerl/ithreads_cloning.pm
perl/modperl/branches/clone-skip-unstable/xs/APR/APR/APR.pm
perl/modperl/branches/clone-skip-unstable/xs/APR/Const/Const.pm
perl/modperl/branches/clone-skip-unstable/xs/APR/PerlIO/PerlIO.pm
perl/modperl/branches/clone-skip-unstable/xs/Apache2/Const/Const.pm
perl/modperl/branches/clone-skip-unstable/xs/ModPerl/Const/Const.pm

Modified: 
perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/ithreads.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/ithreads.t?rev=165215r1=165214r2=165215view=diff
==
--- perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/ithreads.t 
(original)
+++ perl/modperl/branches/clone-skip-unstable/ModPerl-Registry/t/ithreads.t Thu 
Apr 28 15:24:43 2005
@@ -9,8 +9,12 @@
 
 use constant HAS_ITHREADS = ($] = 5.008001  $Config{useithreads});
 
-plan tests = 1, need
-{perl 5.8.1 or higher w/ithreads enabled is required = HAS_ITHREADS};
+#plan tests = 1, need
+#{perl 5.8.1 or higher w/ithreads enabled is required = HAS_ITHREADS};
+
+# XXX: this test can not be run as it is, since $r is no longer
+# cloned, need to review if the problem is still relevant
+plan tests = 1, under_construction;
 
 {
 # the order of prints on the server side is not important here,

Modified: perl/modperl/branches/clone-skip-unstable/lib/ModPerl/WrapXS.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/lib/ModPerl/WrapXS.pm?rev=165215r1=165214r2=165215view=diff
==
--- perl/modperl/branches/clone-skip-unstable/lib/ModPerl/WrapXS.pm (original)
+++ perl/modperl/branches/clone-skip-unstable/lib/ModPerl/WrapXS.pm Thu Apr 28 
15:24:43 2005
@@ -639,6 +639,8 @@
 our \$VERSION = '$version';
 $loader\::load __PACKAGE__;
 
+sub CLONE_SKIP { 1 } # mp2 API is not perl-ithread-clonable
+
 $code
 
 1;

Modified: 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_io_apache.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_io_apache.c?rev=165215r1=165214r2=165215view=diff
==
--- 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_io_apache.c 
(original)
+++ 
perl/modperl/branches/clone-skip-unstable/src/modules/perl/modperl_io_apache.c 
Thu Apr 28 15:24:43 2005
@@ -151,6 +151,8 @@
 PerlIOApache *st = PerlIOSelf(f, PerlIOApache);
 modperl_config_req_t *rcfg;
 
+MP_TRACE_o(MP_FUNC, try request_rec obj: 0x%lx, st-r);
+
 if (!st-r) {
 Perl_warn(aTHX_ an attempt to flush a stale IO handle);
 return -1;
@@ -199,11 +201,32 @@
 static IV
 PerlIOApache_popped(pTHX_ PerlIO *f)
 {
-/* XXX: just temp for tracing */
-MP_TRACE_o(MP_FUNC, done);
-return PerlIOBase_popped(aTHX_ f);
+IV code = PerlIOBase_popped(aTHX_ f);
+PerlIOApache *st = PerlIOSelf(f, PerlIOApache);
+
+MP_TRACE_o(MP_FUNC, done with request_rec obj: 0x%lx, st-r);
+/* prevent possible bugs where a stale r will be attempted to be
+ * reused (e.g. dupped filehandle) */
+st-r = NULL;
+
+return code;
 }
 
+static PerlIO *
+PerlIOApache_dup(pTHX_ PerlIO *f, PerlIO *o, CLONE_PARAMS *param, int flags)
+{
+//return NULL;
+//int *x = (int *)NULL;
+//int y = *x;
+//y=y;
+
+PerlIOApache *st = PerlIOSelf(o, PerlIOApache);
+MP_TRACE_o(MP_FUNC, duped: 0x%lx, st-r);
+f = PerlIOBase_dup(aTHX_ f, o, param, flags);
+//st-r = NULL;
+
+return f;
+}
 
 static PerlIO_funcs PerlIO_Apache = {
 sizeof(PerlIO_funcs),
@@ -216,7 +239,7 @@
 PerlIOBase_binmode

svn commit: r164866 - in /perl/modperl/trunk: Changes Makefile.PL

2005-04-26 Thread stas
Author: stas
Date: Tue Apr 26 12:36:36 2005
New Revision: 164866

URL: http://svn.apache.org/viewcvs?rev=164866view=rev
Log:
improve the diagnostics when detecting mp2  1.999022, tell the user
which files and/or dirs need to be removed

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/Makefile.PL

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?rev=164866r1=164865r2=164866view=diff
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Tue Apr 26 12:36:36 2005
@@ -12,6 +12,9 @@
 
 =item 1.999_23-dev
 
+improve the diagnostics when detecting mp2  1.999022, tell the user
+which files and/or dirs need to be removed [Stas]
+
 restore the DESTDIR support partially nuked by the apache2 rename
 branch [Torsten Frtsch torsten.foertsch gmx.net]
 

Modified: perl/modperl/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Makefile.PL?rev=164866r1=164865r2=164866view=diff
==
--- perl/modperl/trunk/Makefile.PL (original)
+++ perl/modperl/trunk/Makefile.PL Tue Apr 26 12:36:36 2005
@@ -9,7 +9,7 @@
 use constant MIN_HTTPD_VERSION_DYNAMIC = '2.0.47';
 use constant MIN_HTTPD_VERSION_STATIC  = '2.0.51';
 
-my($old_modperl_version, $old_modperl_pm);
+my($old_modperl_version, $old_modperl_pm, $old_Apache2_pm);
 
 BEGIN {
 eval {
@@ -18,6 +18,7 @@
 if ($mod_perl::VERSION  1.999_22  $old_mp2) {
 $old_modperl_version = $mod_perl::VERSION;
 $old_modperl_pm = delete $INC{'mod_perl.pm'};
+$old_Apache2_pm = delete $INC{'Apache2.pm'};
 }
 };
 }
@@ -142,10 +143,25 @@
 no collision)\n;
 }
 else {
+my @files = ();
+my @dirs = ();
+push @files, $old_Apache2_pm if $old_Apache2_pm;
+push @dirs, $path
+if $path =~ /Apache2/ or $old_modperl_version  1.99;
+
+my $note = '';
+if (@files || @dirs) {
+$note  = Problematic\n;
+$note .= files: @files\n if @files;
+$note .= dirs: @dirs\n   if @dirs;
+}
+
 print  not ok\n\n;
 print EOI;
 Cannot install mod_perl/$VERSION on top of $vstring
 due to a major API change between mod_perl 1.999_21 and 1.999_22.
+
+$note
 Please nuke the prior mod_perl installation from your site_lib,
 use a different perl to run the installation process, or use the
 PREFIX option when creating your Makefile.  see




svn commit: r164431 - /perl/modperl/trunk/t/apr-ext/error.t /perl/modperl/trunk/t/apr-ext/os.t /perl/modperl/trunk/t/lib/TestAPRlib/error.pm /perl/modperl/trunk/t/lib/TestAPRlib/os.pm /perl/modperl/trunk/todo/bugs_apr_ext

2005-04-23 Thread stas
Author: stas
Date: Sat Apr 23 17:24:47 2005
New Revision: 164431

URL: http://svn.apache.org/viewcvs?rev=164431view=rev
Log:
APR::Error and APR::OS apr-ext basic loading tests
Contributed by: Philip M. Gollucci [EMAIL PROTECTED]

Added:
perl/modperl/trunk/t/apr-ext/error.t   (with props)
perl/modperl/trunk/t/apr-ext/os.t   (with props)
perl/modperl/trunk/t/lib/TestAPRlib/error.pm   (with props)
perl/modperl/trunk/t/lib/TestAPRlib/os.pm   (with props)
Modified:
perl/modperl/trunk/todo/bugs_apr_ext

Added: perl/modperl/trunk/t/apr-ext/error.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/apr-ext/error.t?rev=164431view=auto
==
--- perl/modperl/trunk/t/apr-ext/error.t (added)
+++ perl/modperl/trunk/t/apr-ext/error.t Sat Apr 23 17:24:47 2005
@@ -0,0 +1,11 @@
+#!perl -T
+
+use strict;
+use warnings FATAL = 'all';
+use Apache::Test;
+
+use TestAPRlib::error;
+
+plan tests = TestAPRlib::error::num_of_tests();
+
+TestAPRlib::error::test();

Propchange: perl/modperl/trunk/t/apr-ext/error.t
--
svn:eol-style = native

Added: perl/modperl/trunk/t/apr-ext/os.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/apr-ext/os.t?rev=164431view=auto
==
--- perl/modperl/trunk/t/apr-ext/os.t (added)
+++ perl/modperl/trunk/t/apr-ext/os.t Sat Apr 23 17:24:47 2005
@@ -0,0 +1,11 @@
+#!perl -T
+
+use strict;
+use warnings FATAL = 'all';
+use Apache::Test;
+
+use TestAPRlib::os;
+
+plan tests = TestAPRlib::os::num_of_tests();
+
+TestAPRlib::os::test();

Propchange: perl/modperl/trunk/t/apr-ext/os.t
--
svn:eol-style = native

Added: perl/modperl/trunk/t/lib/TestAPRlib/error.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/lib/TestAPRlib/error.pm?rev=164431view=auto
==
--- perl/modperl/trunk/t/lib/TestAPRlib/error.pm (added)
+++ perl/modperl/trunk/t/lib/TestAPRlib/error.pm Sat Apr 23 17:24:47 2005
@@ -0,0 +1,21 @@
+package TestAPRlib::error;
+
+# testing APR::Error API
+
+use strict;
+use warnings FATAL = 'all';
+
+use Apache::Test;
+use Apache::TestUtil;
+
+use APR::Error;
+
+sub num_of_tests {
+return 1;
+}
+
+sub test {
+ok 1;
+}
+
+1;

Propchange: perl/modperl/trunk/t/lib/TestAPRlib/error.pm
--
svn:eol-style = native

Added: perl/modperl/trunk/t/lib/TestAPRlib/os.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/lib/TestAPRlib/os.pm?rev=164431view=auto
==
--- perl/modperl/trunk/t/lib/TestAPRlib/os.pm (added)
+++ perl/modperl/trunk/t/lib/TestAPRlib/os.pm Sat Apr 23 17:24:47 2005
@@ -0,0 +1,21 @@
+package TestAPRlib::os;
+
+# testing APR::OS API
+
+use strict;
+use warnings FATAL = 'all';
+
+use Apache::Test;
+use Apache::TestUtil;
+
+use APR::OS ();
+
+sub num_of_tests {
+return 1;
+}
+
+sub test {
+ok 1;
+}
+
+1;

Propchange: perl/modperl/trunk/t/lib/TestAPRlib/os.pm
--
svn:eol-style = native

Modified: perl/modperl/trunk/todo/bugs_apr_ext
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/todo/bugs_apr_ext?rev=164431r1=164430r2=164431view=diff
==
--- perl/modperl/trunk/todo/bugs_apr_ext (original)
+++ perl/modperl/trunk/todo/bugs_apr_ext Sat Apr 23 17:24:47 2005
@@ -23,25 +23,4 @@
   desirable.
 
 * modules that we need to add tests for in apr-ext:
-  APR::Date
-  APR::Const
-  APR::URI
-  APR::Base64
-  APR::String
-  APR::Error
-  APR::XSLoader
-  APR::PerlIO
-  APR::OS
-  APR::Socket
-  APR::Brigade
-  APR::Finfo
-  APR::Util
-  APR::Bucket
-  APR::NetLib
-  APR::ThreadMutex
-  APR::SockAddr
-
-  I think that it's enough to just load them, since most of them are
-  already thoroughly tested under mod_perl. Then if we find some
-  running-outside-mod_perl specific bugs we can write specific tests
-  for those.
+  APR::IpSubnet




svn commit: r164338 - /perl/modperl/trunk/lib/Bundle/Apache2.pm

2005-04-22 Thread stas
Author: stas
Date: Fri Apr 22 22:24:59 2005
New Revision: 164338

URL: http://svn.apache.org/viewcvs?rev=164338view=rev
Log:
sort, cleanup

Modified:
perl/modperl/trunk/lib/Bundle/Apache2.pm

Modified: perl/modperl/trunk/lib/Bundle/Apache2.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Bundle/Apache2.pm?rev=164338r1=164337r2=164338view=diff
==
--- perl/modperl/trunk/lib/Bundle/Apache2.pm (original)
+++ perl/modperl/trunk/lib/Bundle/Apache2.pm Fri Apr 22 22:24:59 2005
@@ -24,13 +24,19 @@
 
 Bundle::Apache2 - Install Apache mod_perl2 and related modules
 
+
+
 =head1 SYNOPSIS
 
 Cperl -MCPAN -e 'install Bundle::Apache2'
 
+
+
 =head1 CONTENTS
 
-LWP   - Used in testing
+Bundle::ApacheTest- Needs for testing
+
+CGI  3.08 - Used in testing (it's in core, but some vendors 
exclude it)
 
 Chatbot::Eliza- Used in testing
 
@@ -38,11 +44,12 @@
 
 Devel::Symdump- Symbol table browsing with Apache::Status
 
-CGI  3.08 - Used in testing (it's in core, but some vendors 
exclude it)
-
 IPC::Run3 - Used in testing
 
-Bundle::ApacheTest- Needs for testing
+LWP   - Used in testing
+
+
+
 
 =head1 DESCRIPTION
 
@@ -52,6 +59,8 @@
 along with all the modules contained in the CONTENTS section
 above. Modules that are up to date are not installed, of course.
 
+
+
 =head1 AUTHOR
 
-Doug MacEachern, Stas Bekman
+mod_perl 2 development team




svn commit: r164339 - /perl/modperl/trunk/lib/Bundle/Apache2.pm

2005-04-22 Thread stas
Author: stas
Date: Fri Apr 22 22:25:28 2005
New Revision: 164339

URL: http://svn.apache.org/viewcvs?rev=164339view=rev
Log:
add the missing HTML::HeadParser 

Modified:
perl/modperl/trunk/lib/Bundle/Apache2.pm

Modified: perl/modperl/trunk/lib/Bundle/Apache2.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Bundle/Apache2.pm?rev=164339r1=164338r2=164339view=diff
==
--- perl/modperl/trunk/lib/Bundle/Apache2.pm (original)
+++ perl/modperl/trunk/lib/Bundle/Apache2.pm Fri Apr 22 22:25:28 2005
@@ -44,6 +44,8 @@
 
 Devel::Symdump- Symbol table browsing with Apache::Status
 
+HTML::HeadParser  - Used in testing
+
 IPC::Run3 - Used in testing
 
 LWP   - Used in testing




svn commit: r161973 - perl/modperl/trunk/src/modules/perl/modperl_tipool.c perl/modperl/trunk/src/modules/perl/modperl_tipool.h

2005-04-19 Thread stas
Author: stas
Date: Tue Apr 19 13:48:42 2005
New Revision: 161973

URL: http://svn.apache.org/viewcvs?view=revrev=161973
Log:
spelling: s/aquired/acquired/

Modified:
perl/modperl/trunk/src/modules/perl/modperl_tipool.c
perl/modperl/trunk/src/modules/perl/modperl_tipool.h

Modified: perl/modperl/trunk/src/modules/perl/modperl_tipool.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_tipool.c?view=diffr1=161972r2=161973
==
--- perl/modperl/trunk/src/modules/perl/modperl_tipool.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_tipool.c Tue Apr 19 13:48:42 
2005
@@ -224,7 +224,7 @@
 
 listp-data = data;
 
-/* assuming tipool-tiplock has already been aquired */
+/* assuming tipool-tiplock has already been acquired */
 
 tipool-idle = modperl_list_append(tipool-idle, listp);
 
@@ -236,7 +236,7 @@
 
 void modperl_tipool_remove(modperl_tipool_t *tipool, modperl_list_t *listp)
 {
-/* assuming tipool-tiplock has already been aquired */
+/* assuming tipool-tiplock has already been acquired */
 
 tipool-idle = modperl_list_remove(tipool-idle, listp);
 

Modified: perl/modperl/trunk/src/modules/perl/modperl_tipool.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_tipool.h?view=diffr1=161972r2=161973
==
--- perl/modperl/trunk/src/modules/perl/modperl_tipool.h (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_tipool.h Tue Apr 19 13:48:42 
2005
@@ -76,7 +76,7 @@
 #define modperl_tipool_lock(tipool) \
 MP_TRACE_i(MP_FUNC, about to lock tipool in thread 0x%lx\n, MP_TIDF); \
 MUTEX_LOCK(tipool-tiplock); \
-MP_TRACE_i(MP_FUNC, aquired tipool lock\n)
+MP_TRACE_i(MP_FUNC, acquired tipool lock\n)
 
 #define modperl_tipool_unlock(tipool) \
 MP_TRACE_i(MP_FUNC, about to unlock tipool in thread 0x%lx\n, MP_TIDF); \




svn commit: r161793 - in perl/modperl/trunk: Changes lib/ModPerl/BuildMM.pm

2005-04-18 Thread stas
Author: stas
Date: Mon Apr 18 13:07:27 2005
New Revision: 161793

URL: http://svn.apache.org/viewcvs?view=revrev=161793
Log:
fix the pod2man'ification part of 'make install' (using POD2MAN_EXE
instead of POD2MAN Makefile macro)

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/ModPerl/BuildMM.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=161792r2=161793
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon Apr 18 13:07:27 2005
@@ -12,6 +12,8 @@
 
 =item 1.999_23-dev
 
+fix the pod2man'ification part of 'make install' (using POD2MAN_EXE
+instead of POD2MAN Makefile macro) [Stas]
 
 
 =item 1.999_22

Modified: perl/modperl/trunk/lib/ModPerl/BuildMM.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/BuildMM.pm?view=diffr1=161792r2=161793
==
--- perl/modperl/trunk/lib/ModPerl/BuildMM.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/BuildMM.pm Mon Apr 18 13:07:27 2005
@@ -255,7 +255,7 @@
 $man =~ s!/!::!g;
 
 push @target,
-'$(NOECHO) $(POD2MAN) --section=3 ' .
+'$(NOECHO) $(POD2MAN_EXE) --section=3 ' .
 $podpath \$(INST_MAN3DIR)/$man.\$(MAN3EXT)
 }
 }




svn commit: r161795 - in perl/modperl/trunk: Changes lib/ModPerl/BuildMM.pm

2005-04-18 Thread stas
Author: stas
Date: Mon Apr 18 13:21:49 2005
New Revision: 161795

URL: http://svn.apache.org/viewcvs?view=revrev=161795
Log:
fix the generation of the manpages for .pm files from sub-projects
like ModPerl-Registry (previously was creating manpage files like
.::ModPerl::PerlRun.3)

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/ModPerl/BuildMM.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=161794r2=161795
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon Apr 18 13:21:49 2005
@@ -12,6 +12,10 @@
 
 =item 1.999_23-dev
 
+fix the generation of the manpages for .pm files from sub-projects
+like ModPerl-Registry (previously was creating manpage files like
+.::ModPerl::PerlRun.3) [Stas]
+
 fix the pod2man'ification part of 'make install' (using POD2MAN_EXE
 instead of POD2MAN Makefile macro) [Stas]
 

Modified: perl/modperl/trunk/lib/ModPerl/BuildMM.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/BuildMM.pm?view=diffr1=161794r2=161795
==
--- perl/modperl/trunk/lib/ModPerl/BuildMM.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/BuildMM.pm Mon Apr 18 13:21:49 2005
@@ -234,6 +234,8 @@
 }
 
 while (my($pm, $blib) = each %pms) {
+$pm   =~ s|/\./|/|g; # clean the path
+$blib =~ s|/\./|/|g; # clean the path
 my @segm = splitdir $blib;
 for my $i (1..2) {
 # try APR.pm and APR/Bucket.pm




svn commit: r160926 - perl/modperl/trunk/todo/bugs_build

2005-04-11 Thread stas
Author: stas
Date: Mon Apr 11 09:59:43 2005
New Revision: 160926

URL: http://svn.apache.org/viewcvs?view=revrev=160926
Log:
reported to work on FreeBSD 5.3+ when linked with libpthread and not the older 
libc_r library. 
by Philip M. Gollucci [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/todo/bugs_build

Modified: perl/modperl/trunk/todo/bugs_build
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/todo/bugs_build?view=diffr1=160925r2=160926
==
--- perl/modperl/trunk/todo/bugs_build (original)
+++ perl/modperl/trunk/todo/bugs_build Mon Apr 11 09:59:43 2005
@@ -33,7 +33,9 @@
 
http://marc.theaimsgroup.com/?l=apache-modperlm=106399870822612w=2
 It doesn't work with threaded perl/worker mpm,
 seemingly because of the problems with threads on
-FreeBSD (not sure what version).
+FreeBSD (not sure what version). But reported to work
+on FreeBSD 5.3+ when linked with libpthread and not
+the older libc_r library.
 
 HPUX11i DSO
 PA-RISC2.0-thread-multi-LP64




svn commit: r160947 - perl/modperl/trunk/t/lib/TestCommon/Utils.pm

2005-04-11 Thread stas
Author: stas
Date: Mon Apr 11 13:47:02 2005
New Revision: 160947

URL: http://svn.apache.org/viewcvs?view=revrev=160947
Log:
missing 'use Apache2::Connection ();'

Modified:
perl/modperl/trunk/t/lib/TestCommon/Utils.pm

Modified: perl/modperl/trunk/t/lib/TestCommon/Utils.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/lib/TestCommon/Utils.pm?view=diffr1=160946r2=160947
==
--- perl/modperl/trunk/t/lib/TestCommon/Utils.pm (original)
+++ perl/modperl/trunk/t/lib/TestCommon/Utils.pm Mon Apr 11 13:47:02 2005
@@ -6,6 +6,7 @@
 use APR::Brigade ();
 use APR::Bucket ();
 use Apache2::Filter ();
+use Apache2::Connection ();
 
 use Apache2::Const -compile = qw(MODE_READBYTES);
 use APR::Const-compile = qw(SUCCESS BLOCK_READ);




svn commit: r160978 - perl/modperl/trunk/t/filter/TestFilter/in_bbs_consume.pm

2005-04-11 Thread stas
Author: stas
Date: Mon Apr 11 16:14:56 2005
New Revision: 160978

URL: http://svn.apache.org/viewcvs?view=revrev=160978
Log:
missing modules

Modified:
perl/modperl/trunk/t/filter/TestFilter/in_bbs_consume.pm

Modified: perl/modperl/trunk/t/filter/TestFilter/in_bbs_consume.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/TestFilter/in_bbs_consume.pm?view=diffr1=160977r2=160978
==
--- perl/modperl/trunk/t/filter/TestFilter/in_bbs_consume.pm (original)
+++ perl/modperl/trunk/t/filter/TestFilter/in_bbs_consume.pm Mon Apr 11 
16:14:56 2005
@@ -11,6 +11,9 @@
 use Apache2::RequestRec ();
 use Apache2::RequestIO ();
 use Apache2::Filter ();
+use Apache2::Connection ();
+use APR::Brigade ();
+use APR::Bucket ();
 
 use Apache::TestTrace;
 




svn commit: r160562 - in perl/modperl/trunk: Changes src/modules/perl/mod_perl.c src/modules/perl/modperl_handler.c

2005-04-08 Thread stas
Author: stas
Date: Fri Apr  8 09:32:37 2005
New Revision: 160562

URL: http://svn.apache.org/viewcvs?view=revrev=160562
Log:
init the anonsub hash for base perl and each vhost +Parent (previously
was init'ed only for the base perl)

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/mod_perl.c
perl/modperl/trunk/src/modules/perl/modperl_handler.c

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=160561r2=160562
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri Apr  8 09:32:37 2005
@@ -38,6 +38,9 @@
 Apache-server() to Apache2::ServerUtil-server()
 [Geoffrey Young]
 
+init the anonsub hash for base perl and each vhost +Parent (previously
+was init'ed only for the base perl) [Stas]
+
 fix a bug when a non-threaded perl is used and anonymous sub is pushed
 at the server startup (the CV wasn't surviving) [Stas]
 

Modified: perl/modperl/trunk/src/modules/perl/mod_perl.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/mod_perl.c?view=diffr1=160561r2=160562
==
--- perl/modperl/trunk/src/modules/perl/mod_perl.c (original)
+++ perl/modperl/trunk/src/modules/perl/mod_perl.c Fri Apr  8 09:32:37 2005
@@ -314,10 +314,8 @@
 }
 #endif /* MP_COMPAT_1X */
 
-/* things to be done only in the main server */
-if (!s-is_virtual) {
-modperl_handler_anon_init(aTHX_ p);
-}
+/* base perl and each vhost +Parent should have this init'ed */
+modperl_handler_anon_init(aTHX_ p);
 
 if (!modperl_config_apply_PerlRequire(s, scfg, perl, p)) {
 exit(1);

Modified: perl/modperl/trunk/src/modules/perl/modperl_handler.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_handler.c?view=diffr1=160561r2=160562
==
--- perl/modperl/trunk/src/modules/perl/modperl_handler.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_handler.c Fri Apr  8 09:32:37 
2005
@@ -119,13 +119,14 @@
 HV *hv;
 
 if (!(he  (hv = (HV*)HeVAL(he {
-Perl_croak(aTHX_ can't find ANONSUB top entry (get));
+Perl_croak(aTHX_ modperl_handler_anon_add: 
+   can't find ANONSUB top entry (get));
 }
 
 SvREFCNT_inc(cv);
 if (!(*hv_store(hv, anon-name, anon-len, (SV*)cv, anon-hash))) {
 SvREFCNT_dec(cv);
-Perl_croak(aTHX_ hv_store of '%s' has failed!, anon-name);
+Perl_croak(aTHX_ hv_store of anonsub '%s' has failed!, anon-name);
 }
 
 MP_TRACE_h(MP_FUNC, anonsub '%s' added, anon-name);
@@ -140,7 +141,8 @@
 SV *sv;
 
 if (!(he  (hv = (HV*)HeVAL(he {
-Perl_croak(aTHX_ can't find ANONSUB top entry (get));
+Perl_croak(aTHX_ modperl_handler_anon_get: 
+   can't find ANONSUB top entry (get));
 }
 
 if ((he = hv_fetch_he(hv, anon-name, anon-len, anon-hash))) {




svn commit: r160564 - in perl/modperl/trunk: Changes lib/ModPerl/BuildOptions.pm

2005-04-08 Thread stas
Author: stas
Date: Fri Apr  8 10:11:43 2005
New Revision: 160564

URL: http://svn.apache.org/viewcvs?view=revrev=160564
Log:
When parsing Makefile.PL MP_* options, handle correctly the MP_FOO=0
entries
Contributed by: Philip M. Gollucci [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/ModPerl/BuildOptions.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=160563r2=160564
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri Apr  8 10:11:43 2005
@@ -38,6 +38,9 @@
 Apache-server() to Apache2::ServerUtil-server()
 [Geoffrey Young]
 
+When parsing Makefile.PL MP_* options, handle correctly the MP_FOO=0
+entries [Philip M. Gollucci [EMAIL PROTECTED]]
+
 init the anonsub hash for base perl and each vhost +Parent (previously
 was init'ed only for the base perl) [Stas]
 

Modified: perl/modperl/trunk/lib/ModPerl/BuildOptions.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/BuildOptions.pm?view=diffr1=160563r2=160564
==
--- perl/modperl/trunk/lib/ModPerl/BuildOptions.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/BuildOptions.pm Fri Apr  8 10:11:43 2005
@@ -101,7 +101,7 @@
 
 if (/^MP_/) {
 my($key, $val) = split $param_qr, $_, 2;
-$val ||= ;
+$val ||=  unless defined $val  $val eq '0';
 $continue = $val =~ s/\\$// ? $key : ;
 
 if (!$table-{$key} and $opts  UNKNOWN_FATAL) {




svn commit: r160567 - in perl/modperl/trunk: Changes lib/Apache2/Status.pm

2005-04-08 Thread stas
Author: stas
Date: Fri Apr  8 10:29:58 2005
New Revision: 160567

URL: http://svn.apache.org/viewcvs?view=revrev=160567
Log:
fix Apache2::Status which was bailing out on trying to load modules
with dev versions like 2.121_02

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache2/Status.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=160566r2=160567
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri Apr  8 10:29:58 2005
@@ -38,6 +38,9 @@
 Apache-server() to Apache2::ServerUtil-server()
 [Geoffrey Young]
 
+fix Apache2::Status which was bailing out on trying to load modules
+with dev versions like 2.121_02 [Stas]
+
 When parsing Makefile.PL MP_* options, handle correctly the MP_FOO=0
 entries [Philip M. Gollucci [EMAIL PROTECTED]]
 

Modified: perl/modperl/trunk/lib/Apache2/Status.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache2/Status.pm?view=diffr1=160566r2=160567
==
--- perl/modperl/trunk/lib/Apache2/Status.pm (original)
+++ perl/modperl/trunk/lib/Apache2/Status.pm Fri Apr  8 10:29:58 2005
@@ -82,7 +82,9 @@
 # if !$opt we skip the testing for the option
 return 0 if $opt  !status_config($r, $opt);
 return 0 unless eval { require $file };
-return 0 unless $module-VERSION  $module-VERSION = $version;
+my $mod_ver = $module-VERSION;
+$mod_ver =~ s/_.*//; # handle dev versions like 2.121_02
+return 0 unless $mod_ver  $mod_ver = $version;
 
 return 1;
 }




svn commit: r160569 - in perl/modperl/trunk: Changes src/modules/perl/modperl_util.h

2005-04-08 Thread stas
Author: stas
Date: Fri Apr  8 10:35:15 2005
New Revision: 160569

URL: http://svn.apache.org/viewcvs?view=revrev=160569
Log:
revert change 160301, it wasn't needed

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_util.h

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=160568r2=160569
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Fri Apr  8 10:35:15 2005
@@ -53,9 +53,6 @@
 Make sure that CPAN shell doesn't triple over usage of
 $ExtUtils::MakeMaker::VERSION [Randy Kobes]
 
-make sure not to use apr_os_thread_current in debug mode when libapr 
-wasn't built with threads support [Stas]
-
 Apache2::RequestRec-new now sets $r-request_time [Stas]
 
 remove CGI.pm and Apache::Request dependencies from Apache2::Status

Modified: perl/modperl/trunk/src/modules/perl/modperl_util.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_util.h?view=diffr1=160568r2=160569
==
--- perl/modperl/trunk/src/modules/perl/modperl_util.h (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_util.h Fri Apr  8 10:35:15 2005
@@ -102,11 +102,7 @@
 void modperl_package_unload(pTHX_ const char *package);
 #if defined(MP_TRACE)  defined(APR_HAS_THREADS)
 #define MP_TRACEf_TID   /tid 0x%lx
-#if APR_HAS_THREADS
 #define MP_TRACEv_TID   (unsigned long)apr_os_thread_current()
-#else
-#define MP_TRACEv_TID   0
-#endif
 #define MP_TRACEv_TID_  MP_TRACEv_TID,
 #define MP_TRACEv__TID  ,MP_TRACEv_TID
 #else




svn commit: r160609 - perl/modperl/trunk/src/modules/perl/modperl_perl.c

2005-04-08 Thread stas
Author: stas
Date: Fri Apr  8 14:13:41 2005
New Revision: 160609

URL: http://svn.apache.org/viewcvs?view=revrev=160609
Log:
fix indent

Modified:
perl/modperl/trunk/src/modules/perl/modperl_perl.c

Modified: perl/modperl/trunk/src/modules/perl/modperl_perl.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_perl.c?view=diffr1=160608r2=160609
==
--- perl/modperl/trunk/src/modules/perl/modperl_perl.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_perl.c Fri Apr  8 14:13:41 2005
@@ -121,8 +121,8 @@
 modperl_perl_ids_t ids;
 modperl_perl_ids_get(ids);
 #ifdef USE_ITHREADS
- modperl_interp_mip_walk_servers(NULL, s,
- modperl_perl_init_ids_mip,
+modperl_interp_mip_walk_servers(NULL, s,
+modperl_perl_init_ids_mip,
 (void*)ids);
 #else
 modperl_perl_init_ids(aTHX_ ids);




svn commit: r160476 - perl/modperl/trunk/t/htdocs/vhost/post_config.pl

2005-04-07 Thread stas
Author: stas
Date: Thu Apr  7 14:48:06 2005
New Revision: 160476

URL: http://svn.apache.org/viewcvs?view=revrev=160476
Log:
fix a bogus dup of the file's content

Modified:
perl/modperl/trunk/t/htdocs/vhost/post_config.pl

Modified: perl/modperl/trunk/t/htdocs/vhost/post_config.pl
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/htdocs/vhost/post_config.pl?view=diffr1=160475r2=160476
==
--- perl/modperl/trunk/t/htdocs/vhost/post_config.pl (original)
+++ perl/modperl/trunk/t/htdocs/vhost/post_config.pl Thu Apr  7 14:48:06 2005
@@ -6,11 +6,3 @@
 $TestVhost::config::restart_count = Apache2::ServerUtil::restart_count();
 
 1;
-use warnings;
-use strict;
-
-use Apache2::ServerUtil ();
-
-$TestVhost::config::Restart_Count = Apache2::ServerUtil::restart_count();
-
-1;




svn commit: r160495 - in perl/modperl/trunk: Changes src/modules/perl/modperl_handler.c t/hooks/TestHooks/push_handlers_anon.pm t/hooks/push_handlers_anon.t

2005-04-07 Thread stas
Author: stas
Date: Thu Apr  7 16:32:47 2005
New Revision: 160495

URL: http://svn.apache.org/viewcvs?view=revrev=160495
Log:
fix a bug when a non-threaded perl is used and anonymous sub is pushed
at the server startup (the CV wasn't surviving)

Added:
perl/modperl/trunk/t/hooks/TestHooks/push_handlers_anon.pm   (with props)
perl/modperl/trunk/t/hooks/push_handlers_anon.t   (with props)
Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/src/modules/perl/modperl_handler.c

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=160494r2=160495
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Thu Apr  7 16:32:47 2005
@@ -18,6 +18,9 @@
  1.99_XX. Please read the below changes carefully.
 ***
 
+fix a bug when a non-threaded perl is used and anonymous sub is pushed
+at the server startup (the CV wasn't surviving) [Stas]
+
 s/Apache::/Apache2::/g and s/mod_perl/mod_perl2/g in all module
 APIs.  so, Apache::RequestRec is now Apache2::RequestRec,
 Apache::compat is now Apache2::compat, and so on. [joes]

Modified: perl/modperl/trunk/src/modules/perl/modperl_handler.c
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/src/modules/perl/modperl_handler.c?view=diffr1=160494r2=160495
==
--- perl/modperl/trunk/src/modules/perl/modperl_handler.c (original)
+++ perl/modperl/trunk/src/modules/perl/modperl_handler.c Thu Apr  7 16:32:47 
2005
@@ -49,6 +49,7 @@
  *PerlTransHandler 'sub { ... }'
  * B) run-time perl code
  *$r-push_handlers(PerlTransHandler = sub {  });
+ *$s-push_handlers(PerlTransHandler = sub {  });
  *
  * In the case of non-threaded perl, we just compile A or grab B and
  * store it in the mod_perl struct and call it when it's used. No
@@ -169,6 +170,7 @@
 #else
 /* it's safe to cache and later use the cv, since the same perl
  * interpeter is always used */
+SvREFCNT_inc((SV*)cv);
 handler-cv   = cv;
 handler-name = NULL;
 

Added: perl/modperl/trunk/t/hooks/TestHooks/push_handlers_anon.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/hooks/TestHooks/push_handlers_anon.pm?view=autorev=160495
==
--- perl/modperl/trunk/t/hooks/TestHooks/push_handlers_anon.pm (added)
+++ perl/modperl/trunk/t/hooks/TestHooks/push_handlers_anon.pm Thu Apr  7 
16:32:47 2005
@@ -0,0 +1,72 @@
+package TestHooks::push_handlers_anon;
+
+# in addition to other anon sub handler tests in push_handlers*, here
+# we test an anon sub added at the server startup. in order not to mess
+# with the rest of the test suite, we run it in its own vhost
+
+use strict;
+use warnings FATAL = 'all';
+
+use Apache2::RequestRec ();
+use Apache2::ServerUtil ();
+use APR::Pool ();
+
+use Apache2::Const -compile = qw(OK DECLINED);
+
+use Apache::Test;
+use Apache::TestUtil;
+
+sub add_note {
+my $r = shift;
+
+my $count = $r-notes-get(add_note) || 0;
+$count++;
+$r-notes-set(add_note, $count);
+Apache2::Const::DECLINED;
+}
+
+# PerlFixupHandlers added at the server startup should add 3 notes
+sub handler {
+my $r = shift;
+
+plan $r, tests = 1;
+
+my $count = $r-notes-get(add_note) || 0;
+ok t_cmp $count, 3, $count callbacks;
+
+Apache2::Const::OK;
+}
+
+1;
+__DATA__
+NoAutoConfig
+# APACHE_TEST_CONFIG_ORDER 1000
+VirtualHost TestHooks::push_handlers_anon
+PerlModuleTestHooks::push_handlers_anon
+Perl 
+# want to push a handler for a vhost, via $s, but the only way to
+# get $s for vhost is to traverse the vhosts list
+use Apache::Test;
+use Apache::TestRequest;
+Apache::TestRequest::module('TestHooks::push_handlers_anon');
+my $hostport = Apache::TestRequest::hostport(Apache::Test::config());
+my($host, $port) = split ':', $hostport;
+my $s = Apache2::ServerUtil-server;
+my $vs = $s-next;
+for (; $vs; $vs = $vs-next) {
+last if $port == $vs-port
+}
+$vs-push_handlers(PerlFixupHandler = 
+   sub { TestHooks::push_handlers_anon::add_note });
+$vs-push_handlers(PerlFixupHandler = 
+   \TestHooks::push_handlers_anon::add_note   );
+$vs-push_handlers(PerlFixupHandler =
+  TestHooks::push_handlers_anon::add_note);
+/Perl
+
+Location /TestHooks__push_handlers_anon
+SetHandler modperl
+PerlResponseHandler TestHooks::push_handlers_anon
+/Location
+/VirtualHost
+/NoAutoConfig

Propchange: perl/modperl/trunk/t/hooks/TestHooks/push_handlers_anon.pm
--
svn:eol-style = native

Added: perl/modperl/trunk/t/hooks/push_handlers_anon.t

svn commit: r160304 - in perl/modperl/trunk: Changes lib/ModPerl/BuildMM.pm

2005-04-06 Thread stas
Author: stas
Date: Wed Apr  6 08:34:38 2005
New Revision: 160304

URL: http://svn.apache.org/viewcvs?view=revrev=160304
Log:
Make sure that CPAN shell doesn't triple over usage of
$ExtUtils::MakeMaker::VERSION

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/ModPerl/BuildMM.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=160303r2=160304
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Wed Apr  6 08:34:38 2005
@@ -18,6 +18,9 @@
  1.99_XX. Please read the below changes carefully.
 ***
 
+Make sure that CPAN shell doesn't triple over usage of
+$ExtUtils::MakeMaker::VERSION [Randy Kobes]
+
 make sure not to use apr_os_thread_current in debug mode when libapr 
 wasn't built with threads support [Stas]
 

Modified: perl/modperl/trunk/lib/ModPerl/BuildMM.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/ModPerl/BuildMM.pm?view=diffr1=160303r2=160304
==
--- perl/modperl/trunk/lib/ModPerl/BuildMM.pm (original)
+++ perl/modperl/trunk/lib/ModPerl/BuildMM.pm Wed Apr  6 08:34:38 2005
@@ -189,8 +189,8 @@
 # create a dependency on pm_to_blib subdirs linkext targets to
 # allow 'make -j'
 require ExtUtils::MakeMaker;
-my $pm_to_blib = ($ExtUtils::MakeMaker::VERSION = 6.22 
-  $ExtUtils::MakeMaker::VERSION = 6.25 )
+my $mm_ver = $ExtUtils::MakeMaker::VERSION;
+my $pm_to_blib = ($mm_ver = 6.22  $mm_ver = 6.25)
 ? pm_to_blib.ts
 : pm_to_blib;
 my @target = (glue_pods: $pm_to_blib subdirs linkext);




svn commit: r160197 - perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm

2005-04-05 Thread stas
Author: stas
Date: Tue Apr  5 09:34:54 2005
New Revision: 160197

URL: http://svn.apache.org/viewcvs?view=revrev=160197
Log:
make sure that the sockets are blocking

Modified:
perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm

Modified: perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm?view=diffr1=160196r2=160197
==
--- perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm (original)
+++ perl/modperl/trunk/t/protocol/TestProtocol/eliza.pm Tue Apr  5 09:34:54 2005
@@ -18,6 +18,17 @@
 my Apache2::Connection $c = shift;
 my APR::Socket $socket = $c-client_socket;
 
+# starting from Apache 2.0.49 several platforms require you to set
+# the socket to a blocking IO mode
+my $nonblocking = $socket-opt_get(APR::Const::SO_NONBLOCK);
+if ($nonblocking) {
+$socket-opt_set(APR::Const::SO_NONBLOCK, 0);
+
+# test that we really *are* in the blocking mode
+!$socket-opt_get(APR::Const::SO_NONBLOCK)
+or die failed to set blocking mode;
+}
+
 my $last = 0;
 while ($socket-recv(my $buff, BUFF_LEN)) {
 # \r is sent instead of \n if the client is talking over telnet




svn commit: r160200 - in perl/modperl/trunk: Changes xs/Apache2/RequestUtil/Apache2__RequestUtil.h

2005-04-05 Thread stas
Author: stas
Date: Tue Apr  5 09:56:36 2005
New Revision: 160200

URL: http://svn.apache.org/viewcvs?view=revrev=160200
Log:
Apache2::RequestRec-new now sets $r-request_time

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/xs/Apache2/RequestUtil/Apache2__RequestUtil.h

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=160199r2=160200
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Tue Apr  5 09:56:36 2005
@@ -18,6 +18,8 @@
  1.99_XX. Please read the below changes carefully.
 ***
 
+Apache2::RequestRec-new now sets $r-request_time [Stas]
+
 s/Apache::/Apache2::/g and s/mod_perl/mod_perl2/g in all module
 APIs [joes].
 

Modified: perl/modperl/trunk/xs/Apache2/RequestUtil/Apache2__RequestUtil.h
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/xs/Apache2/RequestUtil/Apache2__RequestUtil.h?view=diffr1=160199r2=160200
==
--- perl/modperl/trunk/xs/Apache2/RequestUtil/Apache2__RequestUtil.h (original)
+++ perl/modperl/trunk/xs/Apache2/RequestUtil/Apache2__RequestUtil.h Tue Apr  5 
09:56:36 2005
@@ -79,6 +79,8 @@
 r-connection = c;
 r-server = s;
 
+r-request_time = apr_time_now();
+
 r-user= NULL;
 r-ap_auth_type= NULL;
 




svn commit: r159313 - in perl/modperl/trunk: Changes lib/Apache/Reload.pm

2005-03-28 Thread stas
Author: stas
Date: Mon Mar 28 13:26:07 2005
New Revision: 159313

URL: http://svn.apache.org/viewcvs?view=revrev=159313
Log:
Fixes for Apache::Reload's touchfile feature (return Apache::OK
instead of 1)
Contributed by: Chris Warren [EMAIL PROTECTED]

Modified:
perl/modperl/trunk/Changes
perl/modperl/trunk/lib/Apache/Reload.pm

Modified: perl/modperl/trunk/Changes
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/Changes?view=diffr1=159312r2=159313
==
--- perl/modperl/trunk/Changes (original)
+++ perl/modperl/trunk/Changes Mon Mar 28 13:26:07 2005
@@ -12,6 +12,13 @@
 
 =item 1.999_22-dev
 
+Fixes for Apache::Reload's touchfile feature (return Apache::OK
+instead of 1) [Chris Warren [EMAIL PROTECTED]]
+
+cygwin fixes: [Nick *** [EMAIL PROTECTED]]
+- doesn't like XS wrapper starting with 'static'
+- need to compile everything with -DCYGWIN
+
 ModPerl::RegistryCooker API change: s/rewrite_shebang/shebang_to_perl/
 the new API now returns the string to prepend before the rest of the
 script, instead of rewriting the content, which is both faster and

Modified: perl/modperl/trunk/lib/Apache/Reload.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/lib/Apache/Reload.pm?view=diffr1=159312r2=159313
==
--- perl/modperl/trunk/lib/Apache/Reload.pm (original)
+++ perl/modperl/trunk/lib/Apache/Reload.pm Mon Mar 28 13:26:07 2005
@@ -95,8 +95,8 @@
 
 if ($TouchFile) {
 warn Checking mtime of $TouchFile\n if $DEBUG;
-my $touch_mtime = (stat $TouchFile)[9] || return 1;
-return 1 unless $touch_mtime  $TouchTime;
+my $touch_mtime = (stat $TouchFile)[9] || return Apache::OK;
+return Apache::OK unless $touch_mtime  $TouchTime;
 $TouchTime = $touch_mtime;
 open my $fh, $TouchFile or die Can't open '$TouchFile': $!;
 $TouchModules = $fh;




svn commit: r159346 - in perl/modperl/trunk/t: filter/TestFilter/in_bbs_body.pm filter/in_bbs_body.t response/TestAPI/sub_request.pm response/TestModperl/endav.pm

2005-03-28 Thread stas
Author: stas
Date: Mon Mar 28 20:15:05 2005
New Revision: 159346

URL: http://svn.apache.org/viewcvs?view=revrev=159346
Log:
fix various test accounting bugs revealed by Test::More

Modified:
perl/modperl/trunk/t/filter/TestFilter/in_bbs_body.pm
perl/modperl/trunk/t/filter/in_bbs_body.t
perl/modperl/trunk/t/response/TestAPI/sub_request.pm
perl/modperl/trunk/t/response/TestModperl/endav.pm

Modified: perl/modperl/trunk/t/filter/TestFilter/in_bbs_body.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/TestFilter/in_bbs_body.pm?view=diffr1=159345r2=159346
==
--- perl/modperl/trunk/t/filter/TestFilter/in_bbs_body.pm (original)
+++ perl/modperl/trunk/t/filter/TestFilter/in_bbs_body.pm Mon Mar 28 20:15:05 
2005
@@ -46,7 +46,7 @@
 $r-puts($data);
 }
 else {
-$r-puts(1..1\nok 1\n);
+$r-puts(1..3\nok 1\n);
 }
 
 Apache::OK;

Modified: perl/modperl/trunk/t/filter/in_bbs_body.t
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/filter/in_bbs_body.t?view=diffr1=159345r2=159346
==
--- perl/modperl/trunk/t/filter/in_bbs_body.t (original)
+++ perl/modperl/trunk/t/filter/in_bbs_body.t Mon Mar 28 20:15:05 2005
@@ -1,14 +1,13 @@
 use strict;
 use warnings FATAL = 'all';
 
-use Apache::Test;
 use Apache::TestRequest;
 
-plan tests = 2;
-
 my $location = '/TestFilter__in_bbs_body';
 
-for my $x (1,2) {
+print GET_BODY_ASSERT $location;
+
+for my $x (2..3) {
 my $data = scalar reverse ok $x\n;
 print POST_BODY_ASSERT $location, content = $data;
 }

Modified: perl/modperl/trunk/t/response/TestAPI/sub_request.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestAPI/sub_request.pm?view=diffr1=159345r2=159346
==
--- perl/modperl/trunk/t/response/TestAPI/sub_request.pm (original)
+++ perl/modperl/trunk/t/response/TestAPI/sub_request.pm Mon Mar 28 20:15:05 
2005
@@ -30,7 +30,7 @@
 ok t_cmp $subr-uri, $uri, uri;
 
 my $rc = $subr-run;
-ok $rc, Apache::SERVER_ERROR, rc;
+ok t_cmp $rc, Apache::SERVER_ERROR, rc;
 
 # test an explicit DESTROY (which happens automatically on the
 # scope exit)

Modified: perl/modperl/trunk/t/response/TestModperl/endav.pm
URL: 
http://svn.apache.org/viewcvs/perl/modperl/trunk/t/response/TestModperl/endav.pm?view=diffr1=159345r2=159346
==
--- perl/modperl/trunk/t/response/TestModperl/endav.pm (original)
+++ perl/modperl/trunk/t/response/TestModperl/endav.pm Mon Mar 28 20:15:05 2005
@@ -12,7 +12,7 @@
 sub handler {
 my $r = shift;
 
-plan $r, test = 4;
+plan $r, tests = 4;
 
 #just to make sure we dont segv with bogus values
 my $not = 'NoSuchPackage';




  1   2   3   4   5   6   7   8   9   10   >