Changeset 672 for trunk


Ignore:
Timestamp:
01/15/15 14:53:44 (9 years ago)
Author:
Kris Deugau
Message:

/trunk

Fix some subtle) or possibly not-so-sublte) snafus exposed by calls
from IPDB

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dns-rpc.cgi

    r671 r672  
    547547      if (scalar(@$reclist) == 0) {
    548548        # Aren't Magic Numbers Fun?  See pseudotype list in dnsadmin.
    549         my $type = ($cidr->{isv6} ? 65284 : ($cidr->masklen == 32 ? 65280 : 65283) );
     549        my $type = ($cidr->{isv6} ? ($cidr->masklen == 128 ? 65281 : 65284) : ($cidr->masklen == 32 ? 65280 : 65283) );
    550550        rpc_addRec(defrec => 'n', revrec => 'y', parent_id => $zonelist->[0]->{rdns_id}, type => $type,
    551551          address => "$cidr", %args);
     
    558558          next unless $rec->{val} eq $filt;     # make sure we really update the record we want to update.
    559559          updateRec(defrec =>'n', revrec => 'y', id => $rec->{record_id},
    560             parent_id => $zonelist->[0]->{rdns_id}, %args);
     560            parent_id => $zonelist->[0]->{rdns_id}, address => "$cidr", %args);
    561561          $flag = 1;
    562562          last; # only do one record.
     
    648648          # Re-add one to match the parent if we've been given a pattern to use.
    649649          rpc_addRec(defrec => 'n', revrec => 'y', parent_id => $zonelist->[0]->{rdns_id},
    650                  type => ($zone->{isv6} ? 65284 : 65283), address => "$cidr", %args);
     650                 type => ($zone->{isv6} ? 65284 : 65283), address => "$cidr", name => $args{parpatt}, %args);
    651651        }
    652652
Note: See TracChangeset for help on using the changeset viewer.