Changeset 13


Ignore:
Timestamp:
10/25/04 17:30:13 (20 years ago)
Author:
Kris Deugau
Message:

main.cgi: Fix broken or not-quite-right SQL statements

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/cgi-bin/main.cgi

    r12 r13  
    857857      }
    858858      $sql = "select * from freeblocks where city='$city' and maskbits<=$webvar{maskbits}".
    859         " and routed='y' order by maskbits desc";
     859        " and routed='y' order by cidr,maskbits desc";
    860860    }
    861861    $sth = $ip_dbh->prepare($sql);
     
    14241424        if ($webvar{alloctype} =~ /^[sdcmw]p$/) {
    14251425          # We have to delete the IPs from the pool listing.
    1426           $sth = $ip_dbh->prepare("delete * from poolips where pool='$webvar{block}'");
     1426          $sth = $ip_dbh->prepare("delete from poolips where pool='$webvar{block}'");
    14271427          $sth->execute;
    14281428        }
     
    14651465        $sth = $ip_dbh->prepare("delete from freeblocks where cidr=?");
    14661466        foreach my $block (@combinelist) {
    1467           $sth->execute($block);
     1467          $sth->execute("$block");
    14681468        }
    14691469      }
Note: See TracChangeset for help on using the changeset viewer.