- From: Ville Skytta via cvs-syncmail <cvsmail@w3.org>
- Date: Wed, 20 Jul 2005 13:26:03 +0000
- To: www-validator-cvs@w3.org
Update of /sources/public/validator/httpd/cgi-bin
In directory hutz:/tmp/cvs-serv19778/httpd/cgi-bin
Modified Files:
check
Log Message:
Mark running under mod_perl explicitly unsupported, and remove related code.
IPC::Run doesn't seem to help any more with mod_perl 2.0.1, and we have
a few new globals which would need reworking anyway.
Index: check
===================================================================
RCS file: /sources/public/validator/httpd/cgi-bin/check,v
retrieving revision 1.423
retrieving revision 1.424
diff -u -d -r1.423 -r1.424
--- check 20 Jun 2005 08:11:44 -0000 1.423
+++ check 20 Jul 2005 13:26:01 -0000 1.424
@@ -94,7 +94,7 @@
#
# Define global variables.
-use vars qw($DEBUG $CFG $RSRC $VERSION $HAVE_IPC_RUN);
+use vars qw($DEBUG $CFG $RSRC $VERSION);
#
@@ -195,22 +195,6 @@
}
#
- # Use IPC::Run on mod_perl if it's available, IPC::Open3 otherwise.
- $HAVE_IPC_RUN = 0;
- if ($ENV{MOD_PERL}) {
- eval {
- local $SIG{__DIE__};
- require IPC::Run;
- IPC::Run->import('run', 'timeout');
- };
- $HAVE_IPC_RUN = !$@;
- }
- unless ($HAVE_IPC_RUN) {
- require IPC::Open3;
- IPC::Open3->import('open3');
- }
-
- #
# Set debug flag.
if ($CFG->{'Allow Debug'} == TRUE) {
$DEBUG = TRUE if $ENV{W3C_VALIDATOR_DEBUG} || $CFG->{'Enable Debug'};
@@ -687,19 +671,13 @@
#
# Run it through SP, redirecting output to temporary files.
- if ($HAVE_IPC_RUN) {
- local $^W = 0;
- run(\@cmd, $spin, $spout, $sperr, timeout(60));
- undef $spin;
- } else {
- my $pid = do {
- no warnings 'once';
- local(*SPIN, *SPOUT, *SPERR) = ($spin, $spout, $sperr);
- open3("<&SPIN", ">&SPOUT", ">&SPERR", @cmd);
- };
- undef $spin;
- waitpid $pid, 0;
- }
+ my $pid = do {
+ no warnings 'once';
+ local(*SPIN, *SPOUT, *SPERR) = ($spin, $spout, $sperr);
+ open3("<&SPIN", ">&SPOUT", ">&SPERR", @cmd);
+ };
+ undef $spin;
+ waitpid $pid, 0;
#
# Rewind temporary filehandles.
Received on Wednesday, 20 July 2005 13:26:07 UTC