Changeset 14920 in josm


Ignore:
Timestamp:
2019-03-23T16:38:45+01:00 (9 months ago)
Author:
stoecker
Message:

see #16123 - use port 443 for tests always, not a specified non-standard port - last variant failed with {switch:...} statements

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/scripts/TestHTTPS.pl

    r14919 r14920  
    3333    for my $e ($xpc->findnodes(".//j:*", $entry))
    3434    {
    35       if($e->textContent =~ /^http:\/\/(.*?)[\/:]/)
     35      if($e->textContent =~ /^http:\/\/(.*?)(:\d+)?[\/]/)
    3636      {
    3737        my $u = $1;
     
    7272      }
    7373    }
    74     if($line =~ /http:\/\/(.*?)[\/:]/)
     74    if($line =~ /http:\/\/(.*?)(:\d+)?[\/]/)
    7575    {
    7676      $urls{$1}{$name}++;
     
    9393
    9494open OUTFILE,">","josm_https.txt" or die "Could not open output file";
     95open OUTFILENH,">","josm_no_https.txt" or die "Could not open no-https output file";
    9596
    9697sub doprint($)
     
    150151    doprint "* $url [$code $mess]: $i\n";
    151152  };
    152   if($@ && $@ !~ "(--Alarm--|Connection refused)")
     153  if($@)
    153154  {
    154     my $e = $@;
     155    my $e = $@||"";
    155156    $e =~ s/[\r\n]//g;
    156157    $e =~ s/ at scripts\/TestHTTPS.pl .*//;
    157     doprint "* $url [Error $e] :$i\n";
     158    if($@ !~ "(--Alarm--|Connection refused)")
     159    {
     160      doprint "* $url [Error $e] :$i\n";
     161    }
     162    elsif($@)
     163    {
     164      print OUTFILENH "* $url [$e] :$i\n";
     165    }
    158166  }
    159167}
Note: See TracChangeset for help on using the changeset viewer.