BIND 10 #3084: Changes to MySQL backend/lease tables to store FQDN information for a lease

BIND 10 Development do-not-reply at isc.org
Thu Aug 29 12:34:31 UTC 2013


#3084: Changes to MySQL backend/lease tables to store FQDN information for a lease
-------------------------------------+-------------------------------------
            Reporter:  marcin        |                        Owner:
                Type:  enhancement   |  marcin
            Priority:  medium        |                       Status:
           Component:  dhcp-ddns     |  reviewing
            Keywords:                |                    Milestone:
           Sensitive:  0             |  Sprint-DHCP-20130904
         Sub-Project:  DHCP          |                   Resolution:
Estimated Difficulty:  0             |                 CVSS Scoring:
         Total Hours:  0             |              Defect Severity:  N/A
                                     |  Feature Depending on Ticket:
                                     |          Add Hours to Ticket:  0
                                     |                    Internal?:  0
-------------------------------------+-------------------------------------
Changes (by tmark):

 * owner:  tmark => marcin


Comment:

 Nicely done.  Just as I was writing up the need for tests against too long
 a hostname, I saw them added as the last commit for this ticket.

 One minor issue, some cppcheck complaints, and a general question. First
 the minor issue:

 ---------------------------------------------------

 In  MySqlLease4Exchange::createBindForSend(const Lease4Ptr& lease)

 Shouldn't you have done this:

     bind_[8].buffer = reinterpret_cast<char *>(const_cast<char*>
 (lease_->hostname_.c_str()));

 instead of this?

     bind_[8].buffer = const_cast<char*>(lease_->hostname_.c_str());

 --------------------------------------------------------

 I get the following cppcheck errors:

 src/lib/dhcpsrv/mysql_lease_mgr.cc:303: check_fail: Member variable
 'MySqlLease4Exchange::hostname_buffer_' is not initialized in the
 constructor. (warning,uninitMemberVar)
 src/lib/dhcpsrv/mysql_lease_mgr.cc:303: check_fail: Member variable
 'MySqlLease4Exchange::hostname_length_' is not initialized in the
 constructor. (warning,uninitMemberVar)
 src/lib/dhcpsrv/mysql_lease_mgr.cc:655: check_fail: Member variable
 'MySqlLease6Exchange::hostname_buffer_' is not initialized in the
 constructor. (warning,uninitMemberVar)
 src/lib/dhcpsrv/mysql_lease_mgr.cc:655: check_fail: Member variable
 'MySqlLease6Exchange::hostname_length_' is not initialized in the
 constructor. (warning,uninitMemberVar)


 -----------------------------------------------------

 Now the general question:

 Are we likely to ever need/want the ability to fetch a lease by hostname?



 Beyond that everything looks good.

-- 
Ticket URL: <http://bind10.isc.org/ticket/3084#comment:6>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list