Ignore:
Timestamp:
11/09/12 11:57:22 (12 years ago)
Author:
Kris Deugau
Message:

/branches/stable

Minimal server-meltdown-prevention patch for IPv6; create the
block but don't populate IP pools. See #22, sort of.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/stable/cgi-bin/main.cgi

    r508 r549  
    888888        $webvar{circid}, $webvar{privdata}, $webvar{node});
    889889
    890   if ($code eq 'OK') {
     890  if ($code eq 'OK' || $code eq 'WARN') {
    891891    if ($webvar{alloctype} =~ /^.i$/) {
    892892      $msg =~ s|/32||;
     
    902902    } else {
    903903      my $netblock = new NetAddr::IP $webvar{fullcidr};
    904       print qq(<div class="center"><div class="heading">The block $webvar{fullcidr} was ).
    905         "sucessfully added as: $disp_alloctypes{$webvar{alloctype}}</div>".
    906         ( ($webvar{alloctype} eq 'pr' && $webvar{billinguser}) ?
     904      if ($code eq 'OK') {
     905        print qq(<div class="center"><div class="heading">The block $webvar{fullcidr} was ).
     906                "sucessfully added as: $disp_alloctypes{$webvar{alloctype}}</div>";
     907      } else {
     908        print qq(<div class="center"><div class="heading">The block $webvar{fullcidr} was ).
     909                " added as $disp_alloctypes{$webvar{alloctype}} with a warning:<br>$msg</div>";
     910      }
     911      print ( ($webvar{alloctype} eq 'pr' && $webvar{billinguser}) ?
    907912                qq(<div><a href="https://billing.example.com/radius.pl?).
    908913                "action=new_radius_user&custid=$webvar{custid}&userid=$webvar{billinguser}".
Note: See TracChangeset for help on using the changeset viewer.