Changeset 276 for trunk


Ignore:
Timestamp:
03/15/12 16:44:53 (13 years ago)
Author:
Kris Deugau
Message:

/trunk

Add revID sub to match domainID for consistency

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/DNSDB.pm

    r275 r276  
    3939        &changeGroup
    4040        &loadConfig &connectDB &finish
    41         &addDomain &delZone &domainName &revName &domainID &addRDNS
     41        &addDomain &delZone &domainName &revName &domainID &revID &addRDNS
    4242        &getZoneCount &getZoneList
    4343        &addGroup &delGroup &getChildren &groupName
     
    6161                &changeGroup
    6262                &loadConfig &connectDB &finish
    63                 &addDomain &delZone &domainName &revName &domainID &addRDNS
     63                &addDomain &delZone &domainName &revName &domainID &revID &addRDNS
    6464                &getZoneCount &getZoneList
    6565                &addGroup &delGroup &getChildren &groupName
     
    13661366  return $domid if $domid;
    13671367} # end domainID()
     1368
     1369
     1370## DNSDB::revID()
     1371# Takes a database handle and reverse zone name
     1372# Returns the rDNS ID number
     1373sub revID {
     1374  $errstr = '';
     1375  my $dbh = shift;
     1376  my $revzone = shift;
     1377  my ($revid) = $dbh->selectrow_array("SELECT rdns_id FROM revzones WHERE revnet=?", undef, ($revzone) );
     1378  $errstr = $DBI::errstr if !$revid;
     1379  return $revid if $revid;
     1380} # end revID()
    13681381
    13691382
Note: See TracChangeset for help on using the changeset viewer.