BIND 10 trac2414, updated. f25544eeedb66a4f5bb0e0c41387e2e58555daa9 [2414] Minor corrections to comments and spacing between operators

BIND 10 source code commits bind10-changes at lists.isc.org
Mon Nov 5 19:37:06 UTC 2012


The branch, trac2414 has been updated
       via  f25544eeedb66a4f5bb0e0c41387e2e58555daa9 (commit)
      from  50c262d64042f0350cc887b1f51000294bc74b5c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit f25544eeedb66a4f5bb0e0c41387e2e58555daa9
Author: Stephen Morris <stephen at isc.org>
Date:   Mon Nov 5 18:41:18 2012 +0000

    [2414] Minor corrections to comments and spacing between operators

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

Summary of changes:
 src/bin/dhcp6/dhcp6_messages.mes          |    7 +------
 src/bin/dhcp6/tests/dhcp6_srv_unittest.cc |    4 ++--
 src/lib/dhcp/addr_utilities.cc            |   10 +++++-----
 3 files changed, 8 insertions(+), 13 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/bin/dhcp6/dhcp6_messages.mes b/src/bin/dhcp6/dhcp6_messages.mes
index e83da9c..d5d3b72 100644
--- a/src/bin/dhcp6/dhcp6_messages.mes
+++ b/src/bin/dhcp6/dhcp6_messages.mes
@@ -51,7 +51,7 @@ server is about to open sockets on the specified port.
 This debug message indicates that the server successfully advertised
 a lease. It is up to the client to choose one server out of othe advertised
 and continue allocation with that server. This is a normal behavior and
-incicates successful operation.
+indicates successful operation.
 
 % DHCP6_LEASE_ALLOC lease %1 has been allocated (client duid=%2, iaid=%3)
 This debug message indicates that the server successfully granted (in
@@ -153,11 +153,6 @@ to a misconfiguration of the server. The packet processing will continue, but
 the response will only contain generic configuration parameters and no
 addresses or prefixes.
 
-This is a warning message that a packet was received, but the server is
-not configured to support the subnet the packet originated from. This
-message means that the received traffic does not match server configuration
-and is likely a configuration issue.
-
 % DHCP6_CONFIG_LOAD_FAIL failed to load configuration: %1
 This critical error message indicates that the initial DHCPv6
 configuration has failed. The server will start, but nothing will be
diff --git a/src/bin/dhcp6/tests/dhcp6_srv_unittest.cc b/src/bin/dhcp6/tests/dhcp6_srv_unittest.cc
index 1acf83e..76f7eff 100644
--- a/src/bin/dhcp6/tests/dhcp6_srv_unittest.cc
+++ b/src/bin/dhcp6/tests/dhcp6_srv_unittest.cc
@@ -439,7 +439,7 @@ TEST_F(Dhcpv6SrvTest, SolicitInvalidHint) {
 // clients in ADVERTISEs. Please note that ADVERTISE is not a guarantee that such
 // and address will be assigned. Had the pool was very small and contained only
 // 2 addresses, the third client would get the same advertise as the first one
-// and this is a correct behavior. It is REQUEST that fill fail for the third
+// and this is a correct behavior. It is REQUEST that will fail for the third
 // client. ADVERTISE is basically saying "if you send me a request, you will
 // probably get an address like this" (there are no guarantees).
 TEST_F(Dhcpv6SrvTest, ManySolicits) {
@@ -571,7 +571,7 @@ TEST_F(Dhcpv6SrvTest, RequestBasic) {
 // clients in REQUEST. Please note that ADVERTISE is not a guarantee that such
 // and address will be assigned. Had the pool was very small and contained only
 // 2 addresses, the third client would get the same advertise as the first one
-// and this is a correct behavior. It is REQUEST that fill fail for the third
+// and this is a correct behavior. It is REQUEST that will fail for the third
 // client. ADVERTISE is basically saying "if you send me a request, you will
 // probably get an address like this" (there are no guarantees).
 TEST_F(Dhcpv6SrvTest, ManyRequests) {
diff --git a/src/lib/dhcp/addr_utilities.cc b/src/lib/dhcp/addr_utilities.cc
index b13c17e..7032a41 100644
--- a/src/lib/dhcp/addr_utilities.cc
+++ b/src/lib/dhcp/addr_utilities.cc
@@ -47,7 +47,7 @@ const uint8_t bitMask6[]= { 0, 0x80, 0xc0, 0xe0, 0xf0, 0xf8, 0xfc, 0xfe, 0xff };
 isc::asiolink::IOAddress firstAddrInPrefix6(const isc::asiolink::IOAddress& prefix,
                                             uint8_t len) {
 
-    if (len>128) {
+    if (len > 128) {
         isc_throw(BadValue, "IPv6 prefix length too large:" << len);
     }
 
@@ -91,11 +91,11 @@ isc::asiolink::IOAddress firstAddrInPrefix6(const isc::asiolink::IOAddress& pref
 /// @param len netmask length (0-32)
 isc::asiolink::IOAddress firstAddrInPrefix4(const isc::asiolink::IOAddress& prefix,
                                             uint8_t len) {
-    uint32_t addr = prefix;
     if (len > 32) {
         isc_throw(isc::BadValue, "Too large netmask. 0..32 is allowed in IPv4");
     }
 
+    uint32_t addr = prefix;
     return (IOAddress(addr & (~bitMask4[len])));
 }
 
@@ -108,11 +108,11 @@ isc::asiolink::IOAddress firstAddrInPrefix4(const isc::asiolink::IOAddress& pref
 /// @param len netmask length (0-32)
 isc::asiolink::IOAddress lastAddrInPrefix4(const isc::asiolink::IOAddress& prefix,
                                            uint8_t len) {
-    uint32_t addr = prefix;
-    if (len>32) {
+    if (len > 32) {
         isc_throw(isc::BadValue, "Too large netmask. 0..32 is allowed in IPv4");
     }
 
+    uint32_t addr = prefix;
     return (IOAddress(addr | bitMask4[len]));
 }
 
@@ -125,7 +125,7 @@ isc::asiolink::IOAddress lastAddrInPrefix4(const isc::asiolink::IOAddress& prefi
 /// @param len netmask length (0-128)
 isc::asiolink::IOAddress lastAddrInPrefix6(const isc::asiolink::IOAddress& prefix,
                                            uint8_t len) {
-    if (len>128) {
+    if (len > 128) {
         isc_throw(BadValue, "IPv6 prefix length too large:" << len);
     }
 



More information about the bind10-changes mailing list