You are viewing a plain text version of this content. The canonical link for it is here.
Posted to test-cvs@httpd.apache.org by st...@apache.org on 2004/12/04 18:39:26 UTC

svn commit: r109816 - /httpd/test/trunk/perl-framework/Apache-Test/Changes /httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm

Author: stas
Date: Sat Dec  4 09:39:25 2004
New Revision: 109816

URL: http://svn.apache.org/viewcvs?view=rev&rev=109816
Log:
fix Apache::TestConfig::open_cmd to run properly under -T

Modified:
   httpd/test/trunk/perl-framework/Apache-Test/Changes
   httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm

Modified: httpd/test/trunk/perl-framework/Apache-Test/Changes
Url: http://svn.apache.org/viewcvs/httpd/test/trunk/perl-framework/Apache-Test/Changes?view=diff&rev=109816&p1=httpd/test/trunk/perl-framework/Apache-Test/Changes&r1=109815&p2=httpd/test/trunk/perl-framework/Apache-Test/Changes&r2=109816
==============================================================================
--- httpd/test/trunk/perl-framework/Apache-Test/Changes	(original)
+++ httpd/test/trunk/perl-framework/Apache-Test/Changes	Sat Dec  4 09:39:25 2004
@@ -8,6 +8,8 @@
 
 =item 1.17-dev
 
+fix Apache::TestConfig::open_cmd to run properly under -T [Stas]
+
 require Cwd 2.06 or higher (to solve File::Spec::rel2abs problems
 under -T). Enforce the modules version requirements for those who
 aren't running under CPAN/CPANPLUS shell) [Stas]

Modified: httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm
Url: http://svn.apache.org/viewcvs/httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm?view=diff&rev=109816&p1=httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm&r1=109815&p2=httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm&r2=109816
==============================================================================
--- httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm	(original)
+++ httpd/test/trunk/perl-framework/Apache-Test/lib/Apache/TestConfig.pm	Sat Dec  4 09:39:25 2004
@@ -1037,10 +1037,13 @@
     # untaint some %ENV fields
     local @ENV{ qw(IFS CDPATH ENV BASH_ENV) };
 
-    # Temporarly untaint PATH
+    # Temporarily untaint PATH
     (local $ENV{PATH}) = ( $ENV{PATH} =~ /(.*)/ );
     # -T disallows relative directories in the PATH
     $ENV{PATH} = join ':', grep !/^\./, split /:/, $ENV{PATH};
+
+    # launder for -T
+    $cmd =~ /(.*)/; $cmd = $1;
 
     my $handle = Symbol::gensym();
     open $handle, "$cmd|" or die "$cmd failed: $!";