[BACK]Return to cvsweb.cgi CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / cvsweb

Diff for /cvsweb/cvsweb.cgi between version 3.14 and 3.15

version 3.14, 2000/08/24 15:53:11 version 3.15, 2000/08/25 09:01:58
Line 949  sub link($$) {
Line 949  sub link($$) {
   
 sub revcmp($$) {  sub revcmp($$) {
         my($rev1, $rev2) = @_;          my($rev1, $rev2) = @_;
   
           # make no comparison for a tag or a branch
           return 0 if $rev1 =~ /[^\d.]/ || $rev2 =~ /[^\d.]/;
   
         my(@r1) = split(/\./, $rev1);          my(@r1) = split(/\./, $rev1);
         my(@r2) = split(/\./, $rev2);          my(@r2) = split(/\./, $rev2);
         my($a,$b);          my($a,$b);
Line 1063  sub doAnnotate($$) {
Line 1067  sub doAnnotate($$) {
   
     # make sure the revisions a wellformed, for security      # make sure the revisions a wellformed, for security
     # reasons ..      # reasons ..
     if (!($rev =~ /^[\d\.]+$/)) {      if ($rev =~ /[^\w.]/) {
         &fatal("404 Not Found",          &fatal("404 Not Found",
                 "Malformed query \"$ENV{QUERY_STRING}\"");                  "Malformed query \"$ENV{QUERY_STRING}\"");
     }      }
Line 1214  sub doCheckout($$) {
Line 1218  sub doCheckout($$) {
     my ($mimetype,$revopt);      my ($mimetype,$revopt);
     my $fh = do {local(*FH);};      my $fh = do {local(*FH);};
   
       if ($rev eq 'HEAD' || $rev eq '.') {
           $rev = undef;
       }
   
     # make sure the revisions a wellformed, for security      # make sure the revisions a wellformed, for security
     # reasons ..      # reasons ..
     if (defined($rev) && !($rev =~ /^[\d\.]+$/)) {      if (defined($rev) && $rev =~ /[^\w.]/) {
         &fatal("404 Not Found",          &fatal("404 Not Found",
                 "Malformed query \"$ENV{QUERY_STRING}\"");                  "Malformed query \"$ENV{QUERY_STRING}\"");
     }      }
Line 1252  sub doCheckout($$) {
Line 1260  sub doCheckout($$) {
     # Safely for a child process to read from.      # Safely for a child process to read from.
     if (! open($fh, "-|")) { # child      if (! open($fh, "-|")) { # child
       open(STDERR, ">&STDOUT"); # Redirect stderr to stdout        open(STDERR, ">&STDOUT"); # Redirect stderr to stdout
       exec("cvs", "-d", $cvsroot, "co", "-p", $revopt, $where);        exec("cvs", "-Rld", $cvsroot, "co", "-p", $revopt, $where);
     }      }
 #===================================================================  #===================================================================
 #Checking out squid/src/ftp.c  #Checking out squid/src/ftp.c
Line 1369  sub doDiff($$$$$$) {
Line 1377  sub doDiff($$$$$$) {
             $rev2 = $tr2;              $rev2 = $tr2;
             $sym2 = "";              $sym2 = "";
         }          }
   
         # make sure the revisions a wellformed, for security          # make sure the revisions a wellformed, for security
         # reasons ..          # reasons ..
         if (!($rev1 =~ /^[\d\.]+$/) || !($rev2 =~ /^[\d\.]+$/)) {          if ($rev1 =~ /[^\w.]/ || $rev2 =~ /[^\w.]/) {
             &fatal("404 Not Found",              &fatal("404 Not Found",
                     "Malformed query \"$ENV{QUERY_STRING}\"");                      "Malformed query \"$ENV{QUERY_STRING}\"");
         }          }
Line 1413  sub doDiff($$$$$$) {
Line 1422  sub doDiff($$$$$$) {
   
         # apply special options          # apply special options
         if ($showfunc) {          if ($showfunc) {
             push @difftype, '-p';              push @difftype, '-p' if $f =~ /^[cHhu]$/;
   
             my($re1, $re2);              my($re1, $re2);
   

Legend:
Removed from v.3.14  
changed lines
  Added in v.3.15

CVSweb