Ignore:
Timestamp:
01/09/26 12:42:23 (8 days ago)
Author:
Kris Deugau
Message:

/branches/cname-collision

Fix SQL logic bug picking out possible colliding records
See #72

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/cname-collision/DNSDB.pm

    r973 r974  
    641641    if ($args{defrec} eq 'n') {
    642642      # Expired records
    643       $sql .= " AND (stampactive = 't' AND (expires = 't' AND stamp >= now()))";
     643      $sql .= " AND (stampactive = 'f' OR (stampactive = 't' AND (expires = 't' AND stamp >= now())))";
    644644    }
    645645    my @lookupargs = ($args{id}, $hcheck);
     
    661661  if ($args{defrec} eq 'n') {
    662662    # Expired records
    663     $sql .= " AND (stampactive = 't' AND (expires = 't' AND stamp >= now()))";
     663    $sql .= " AND (stampactive = 'f' OR (stampactive = 't' AND (expires = 't' AND stamp >= now())))";
    664664  }
    665665  my @lookupargs = ($args{id}, $hcheck);
Note: See TracChangeset for help on using the changeset viewer.