httpd-test-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject cvs commit: httpd-test/perl-framework/Apache-Test/lib/Apache TestRequest.pm
Date Fri, 11 Jul 2003 18:15:54 GMT
stas        2003/07/11 11:15:54

  Modified:    perl-framework/Apache-Test/lib/Apache TestRequest.pm
  Log:
  More RedirectOK fixes from David
  Submitted by:	David Wheeler <david@kineticode.com>
  
  Revision  Changes    Path
  1.82      +9 -9      httpd-test/perl-framework/Apache-Test/lib/Apache/TestRequest.pm
  
  Index: TestRequest.pm
  ===================================================================
  RCS file: /home/cvs/httpd-test/perl-framework/Apache-Test/lib/Apache/TestRequest.pm,v
  retrieving revision 1.81
  retrieving revision 1.82
  diff -u -r1.81 -r1.82
  --- TestRequest.pm	8 Jul 2003 07:56:24 -0000	1.81
  +++ TestRequest.pm	11 Jul 2003 18:15:53 -0000	1.82
  @@ -88,14 +88,13 @@
           $UA = undef;
       }
   
  -    if (my $redir = $args->{requests_redirectable}) {
  +    if (exists $args->{requests_redirectable}) {
  +        my $redir = $args->{requests_redirectable};
           if (ref $redir and (@$redir > 1 or $redir->[0] ne 'POST')) {
               $RedirectOK = 1;
           } else {
               $RedirectOK = 0;
           }
  -    } else {
  -        $RedirectOK = $redir;
       }
   
       $args->{keep_alive} ||= $ENV{APACHE_TEST_HTTP11};
  @@ -298,9 +297,10 @@
   sub UPLOAD {
       my($url, $pass, $keep) = prepare(@_);
   
  -    if (exists $keep->{redirect_ok}) {
  -        local $RedirectOK = $keep->{redirect_ok};
  -    }
  +    local $RedirectOK = exists $keep->{redirect_ok} 
  +        ? $keep->{redirect_ok}
  +        : $RedirectOK;
  +
       if ($keep->{filename}) {
           return upload_file($url, $keep->{filename}, $pass);
       }
  @@ -461,9 +461,9 @@
   
       *$name = sub {
           my($url, $pass, $keep) = prepare(@_);
  -        if (exists $keep->{redirect_ok}) {
  -            local $RedirectOK = $keep->{redirect_ok};
  -        }
  +        local $RedirectOK = exists $keep->{redirect_ok}
  +            ? $keep->{redirect_ok}
  +            : $RedirectOK;
           return lwp_call($method, undef, $url, @$pass);
       };
   
  
  
  

Mime
View raw message