Commit e1938e5c authored by Marcin Siodelski's avatar Marcin Siodelski
Browse files

[3295] Do not generate NCRs if DDNS is disabled.

This is a result of the second review.
parent 41f5d870
......@@ -1044,6 +1044,11 @@ Dhcpv6Srv::processClientFqdn(const Pkt6Ptr& question, const Pkt6Ptr& answer) {
void
Dhcpv6Srv::createNameChangeRequests(const Pkt6Ptr& answer) {
// Don't create NameChangeRequests if DNS updates are disabled.
if (!FQDN_ENABLE_UPDATE) {
return;
}
// The response message instance is always required. For instance it
// holds the Client Identifier. It is a programming error if supplied
// message is NULL.
......@@ -1126,6 +1131,11 @@ Dhcpv6Srv::createNameChangeRequests(const Pkt6Ptr& answer) {
void
Dhcpv6Srv::createRemovalNameChangeRequest(const Lease6Ptr& lease) {
// Don't create NameChangeRequests if DNS updates are disabled.
if (!FQDN_ENABLE_UPDATE) {
return;
}
// If we haven't performed a DNS Update when lease was acquired,
// there is nothing to do here.
if (!lease->fqdn_fwd_ && !lease->fqdn_rev_) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment