You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl-cvs@perl.apache.org by do...@hyperreal.org on 1999/03/26 20:59:50 UTC
cvs commit: modperl/src/modules/perl Apache.xs mod_perl.c mod_perl.h
dougm 99/03/26 11:59:48
Modified: . Changes ToDo
Apache Apache.pm
src/modules/perl Apache.xs mod_perl.c mod_perl.h
Log:
print() now returns true on success, false on failure (1.3.6+)
no longer set SIGPIPE handler if Apache >= 1.3.6
Revision Changes Path
1.270 +4 -0 modperl/Changes
Index: Changes
===================================================================
RCS file: /home/cvs/modperl/Changes,v
retrieving revision 1.269
retrieving revision 1.270
diff -u -r1.269 -r1.270
--- Changes 1999/03/26 19:13:09 1.269
+++ Changes 1999/03/26 19:59:41 1.270
@@ -8,6 +8,10 @@
=item 1.18_01-dev
+print() now returns true on success, false on failure (1.3.6+)
+
+no longer set SIGPIPE handler if Apache >= 1.3.6
+
fix bug triggered when siggv is not initialized, spotted by Preston Brown
new Apache::PerlRun::flush_namespace method to undef() each [SAHC]V
1.168 +0 -8 modperl/ToDo
Index: ToDo
===================================================================
RCS file: /home/cvs/modperl/ToDo,v
retrieving revision 1.167
retrieving revision 1.168
diff -u -r1.167 -r1.168
--- ToDo 1999/03/26 19:13:08 1.167
+++ ToDo 1999/03/26 19:59:42 1.168
@@ -7,10 +7,6 @@
- $r->set_handlers(PerlAuthenHandler => undef) stomps other config!?
-- don't call Apache::SIG->set if 1.3.5
-
-- print() should return true or false
-
- how to manipulate order of handlers (not just Perl*Handlers)
- %Files doesnt work, nor does @DirectoryIndex outside of %Location
@@ -23,8 +19,6 @@
- Makefile.PL should always push load_modules.pl for 'make test'
-- look at using soft_timeout instead of hard_timeout
-
- t/modules/cookie must test have_module "CGI::Cookie"
- dorighthing if t/modules/status.t can see Devel::Symdump, but httpd cant
@@ -38,8 +32,6 @@
- @PerlSetVar core dumps outside of %Location (Ask)
- turn of strip of httpd in Apache's install.sh
-
-- at .../perl/Apache/SIG.pm line 30 (Mark Downing, Ron Hawkins)
---------------------------------------------------------------------------
KNOWN BUGS
1.25 +0 -3 modperl/Apache/Apache.pm
Index: Apache.pm
===================================================================
RCS file: /home/cvs/modperl/Apache/Apache.pm,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- Apache.pm 1999/03/04 15:37:53 1.24
+++ Apache.pm 1999/03/26 19:59:43 1.25
@@ -6,7 +6,6 @@
use Apache::Constants qw(OK DECLINED);
use Apache::Connection ();
use Apache::Server ();
-use Apache::SIG ();
@Apache::EXPORT_OK = qw(exit warn);
@@ -16,8 +15,6 @@
#we must die here outside of httpd so CGI::Switch works
die unless $ENV{MOD_PERL};
}
-
-Apache::SIG->set;
{
no strict;
1.73 +10 -3 modperl/src/modules/perl/Apache.xs
Index: Apache.xs
===================================================================
RCS file: /home/cvs/modperl/src/modules/perl/Apache.xs,v
retrieving revision 1.72
retrieving revision 1.73
diff -u -r1.72 -r1.73
--- Apache.xs 1999/03/08 23:42:53 1.72
+++ Apache.xs 1999/03/26 19:59:45 1.73
@@ -903,17 +903,16 @@
ST(1) = &sv_undef;
}
-void
+int
print(r, ...)
Apache r
ALIAS:
Apache::PRINT = 1
- PREINIT:
+ CODE:
ix = ix; /* avoid -Wall warning */
- CODE:
if(!mod_perl_sent_header(r, 0)) {
SV *sv = sv_newmortal();
SV *rp = ST(0);
@@ -947,6 +946,11 @@
kill_timeout(r);
}
+ RETVAL = !r->connection->aborted;
+
+ OUTPUT:
+ RETVAL
+
int
write_client(r, ...)
Apache r
@@ -989,6 +993,9 @@
RETVAL += sent;
#endif
}
+
+ OUTPUT:
+ RETVAL
#functions from http_request.c
void
1.82 +12 -0 modperl/src/modules/perl/mod_perl.c
Index: mod_perl.c
===================================================================
RCS file: /home/cvs/modperl/src/modules/perl/mod_perl.c,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -r1.81 -r1.82
--- mod_perl.c 1999/03/26 19:13:15 1.81
+++ mod_perl.c 1999/03/26 19:59:46 1.82
@@ -484,6 +484,15 @@
exit(1);
}
+#if !HAS_MMN(MMN_136)
+static void set_sigpipe(void)
+{
+ char *dargs[] = { NULL };
+ perl_require_module("Apache::SIG", NULL);
+ perl_call_argv("Apache::SIG::set", G_DISCARD, dargs);
+}
+#endif
+
void perl_startup (server_rec *s, pool *p)
{
char *argv[] = { NULL, NULL, NULL, NULL, NULL, NULL, NULL };
@@ -533,6 +542,9 @@
if(PERL_RUNNING() && PERL_STARTUP_IS_DONE) {
saveINC;
mp_check_version();
+#if !HAS_MMN(MMN_136)
+ set_sigpipe();
+#endif
}
if(perl_is_running == 0) {
1.74 +2 -0 modperl/src/modules/perl/mod_perl.h
Index: mod_perl.h
===================================================================
RCS file: /home/cvs/modperl/src/modules/perl/mod_perl.h,v
retrieving revision 1.73
retrieving revision 1.74
diff -u -r1.73 -r1.74
--- mod_perl.h 1999/01/27 23:37:30 1.73
+++ mod_perl.h 1999/03/26 19:59:46 1.74
@@ -450,9 +450,11 @@
#define MODULE_MAGIC_AT_LEAST(major,minor) (0 > 1)
#endif
+#define HAS_MMN(mmn) (MODULE_MAGIC_NUMBER >= mmn)
#define MMN_130 19980527
#define MMN_131 19980713
#define MMN_132 19980806
+#define MMN_136 19990320
#if MODULE_MAGIC_NUMBER >= MMN_130
#define HAVE_APACHE_V_130
#endif