stas 2004/01/30 17:46:43
Modified: perl-framework/Apache-Test/lib/Apache TestConfig.pm
Log:
don't set APACHE_TEST_PORT internally as it'll affect the reconfiguration
process (which kicks in if env vars are set)
Revision Changes Path
1.203 +5 -3
httpd-test/perl-framework/Apache-Test/lib/Apache/TestConfig.pm
Index: TestConfig.pm
===================================================================
RCS file:
/home/cvs/httpd-test/perl-framework/Apache-Test/lib/Apache/TestConfig.pm,v
retrieving revision 1.202
retrieving revision 1.203
diff -u -u -r1.202 -r1.203
--- TestConfig.pm 27 Jan 2004 18:12:51 -0000 1.202
+++ TestConfig.pm 31 Jan 2004 01:46:43 -0000 1.203
@@ -561,13 +561,15 @@
# bind() will actually get the port. So there is a need in another
# check and reconfiguration just before the server starts.
#
+my $port_memoized;
sub select_first_port {
my $self = shift;
- my $port ||= $ENV{APACHE_TEST_PORT} || $self->{vars}{port} ||
DEFAULT_PORT;
+ my $port ||= $port_memoized || $ENV{APACHE_TEST_PORT}
+ || $self->{vars}{port} || DEFAULT_PORT;
# memoize
- $ENV{APACHE_TEST_PORT} = $port;
+ $port_memoized = $port;
return $port unless $port eq 'select';
@@ -591,7 +593,7 @@
unless $port == DEFAULT_PORT;
# memoize
- $ENV{APACHE_TEST_PORT} = $port;
+ $port_memoized = $port;
return $port;
}