]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[#413,!288] Addressed review comments.
authorThomas Markwalder <tmark@isc.org>
Wed, 10 Apr 2019 13:31:12 +0000 (09:31 -0400)
committerThomas Markwalder <tmark@isc.org>
Wed, 10 Apr 2019 17:42:16 +0000 (13:42 -0400)
src/lib/dhcpsrv/srv_config.h
src/lib/dhcpsrv/tests/cfg_shared_networks4_unittest.cc
src/lib/dhcpsrv/tests/cfg_shared_networks6_unittest.cc
src/lib/dhcpsrv/tests/srv_config_unittest.cc

index 71636c8270ed8ce00950f03bcb8ccabfbb6d1f4d..61c1aec044da383a5fb85f561b990d423d92a57b 100644 (file)
@@ -628,25 +628,8 @@ private:
     /// @brief Merges the DHCPv4 configuration specified as a parameter into
     /// this configuration.
     ///
-    /// The general rule is that the configuration data from the @c other
-    /// object replaces configuration data held in this object instance.
-    /// The data that do not overlap between the two objects is simply
-    /// inserted into this configuration.
-    ///
-    /// @warning The call to @c merge may modify the data in the @c other
-    /// object. Therefore, the caller must not rely on the data held
-    /// in the @c other object after the call to @c merge. Also, the
-    /// data held in @c other must not be modified after the call to
-    /// @c merge because it may affect the merged configuration.
-    ///
-    /// The @c other parameter must be a @c SrvConfig or its derivation.
-    ///
-    /// Currently, the following parts of the v4 configuration are merged:
-    /// - globals
-    /// - shared-networks
-    /// - subnets
-    ///
-    /// @todo Add support for merging other configuration elements.
+    /// This is called by @c merge() to handle v4 specifics, such as
+    /// networks and subnets.
     ///
     /// @param other An object holding the configuration to be merged
     /// into this configuration.
@@ -655,25 +638,8 @@ private:
     /// @brief Merges the DHCPv6 configuration specified as a parameter into
     /// this configuration.
     ///
-    /// The general rule is that the configuration data from the @c other
-    /// object replaces configuration data held in this object instance.
-    /// The data that do not overlap between the two objects is simply
-    /// inserted into this configuration.
-    ///
-    /// @warning The call to @c merge may modify the data in the @c other
-    /// object. Therefore, the caller must not rely on the data held
-    /// in the @c other object after the call to @c merge. Also, the
-    /// data held in @c other must not be modified after the call to
-    /// @c merge because it may affect the merged configuration.
-    ///
-    /// The @c other parameter must be a @c SrvConfig or its derivation.
-    ///
-    /// Currently, the following parts of the v6 configuration are merged:
-    /// - globals
-    /// - shared-networks
-    /// - subnets
-    ///
-    /// @todo Add support for merging other configuration elements.
+    /// This is called by @c merge() to handle v4 specifics, such as
+    /// networks and subnets.
     ///
     /// @param other An object holding the configuration to be merged
     /// into this configuration.
index 8e9ea86a828cc238f8c1b039ff08c0c2db6841ff..cd4e7ca468cc525d0dceb79ed8a4a8513afb5892 100644 (file)
@@ -18,9 +18,11 @@ using namespace asiolink;
 
 namespace {
 
-/// Attempts to verify an expected network within a collection of networks
+/// @brief Attempts to verify an expected network within a collection
+/// of networks
+///
 /// @param networks set of networks in which to look
-/// @param name name of the expected network 
+/// @param name name of the expected network
 /// @param exp_valid expected valid lifetime of the network
 /// @param exp_subnets list of subnet IDs the network is expected to own
 void checkMergedNetwork(const CfgSharedNetworks4& networks, const std::string& name,
index 5add7d9859c9862adc73dd15601346451fc1991d..44f4b72c26278a604b084660fb0ece20056883f5 100644 (file)
@@ -18,9 +18,11 @@ using namespace asiolink;
 
 namespace {
 
-/// Attempts to verify an expected network within a collection of networks
+/// @brief Attempts to verify an expected network within a collection
+/// of networks
+///
 /// @param networks set of networks in which to look
-/// @param name name of the expected network 
+/// @param name name of the expected network
 /// @param exp_valid expected valid lifetime of the network
 /// @param exp_subnets list of subnet IDs the network is expected to own
 void checkMergedNetwork(const CfgSharedNetworks6& networks, const std::string& name,
index b1a0a09f2878aceb0b512f8a4c61d697b58946eb..0e81acfa9b20d72d3a4c68cb5c27c6feebc2ca86 100644 (file)
@@ -1056,7 +1056,6 @@ TEST_F(SrvConfigTest, mergeGlobals6) {
 
     // Set some explicit values.
     cfg_to.setDeclinePeriod(100);
-    cfg_to.setEchoClientId(false);
     cfg_to.setDhcp4o6Port(777);
     cfg_to.setServerTag("not_this_server");