BIND 10 trac534, updated. 950ffa229928d24ba8ebd74c5945e4cf0facf539 [trac534] some (mostly) editorial changes: - made contextCheck() a const member function - move the comment about exception guarantee from contextCheck() to find() - parentheses around return

BIND 10 source code commits bind10-changes at lists.isc.org
Mon Jan 31 20:35:54 UTC 2011


The branch, trac534 has been updated
       via  950ffa229928d24ba8ebd74c5945e4cf0facf539 (commit)
      from  b086fbca9ce75d8950cd51d0b9de3d49715565a7 (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 950ffa229928d24ba8ebd74c5945e4cf0facf539
Author: JINMEI Tatuya <jinmei at isc.org>
Date:   Mon Jan 31 11:45:12 2011 -0800

    [trac534] some (mostly) editorial changes:
     - made contextCheck() a const member function
     - move the comment about exception guarantee from contextCheck() to find()
     - parentheses around return

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

Summary of changes:
 src/lib/datasrc/memory_datasrc.cc |   15 ++++++++-------
 1 files changed, 8 insertions(+), 7 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/lib/datasrc/memory_datasrc.cc b/src/lib/datasrc/memory_datasrc.cc
index a0a7be5..5d0fdde 100644
--- a/src/lib/datasrc/memory_datasrc.cc
+++ b/src/lib/datasrc/memory_datasrc.cc
@@ -73,13 +73,10 @@ struct MemoryZone::MemoryZoneImpl {
      *
      * If such condition is found, it throws AddError.
      */
-    void contextCheck(const ConstRRsetPtr& rrset, const DomainPtr& domain) {
+    void contextCheck(const ConstRRsetPtr& rrset,
+                      const DomainPtr& domain) const {
         // Ensure CNAME and other type of RR don't coexist for the same
         // owner name.
-        // Note: when the check fails and the exception is thrown, it may
-        // break strong exception guarantee.  At the moment we prefer
-        // code simplicity and don't bother to introduce complicated
-        // recovery code.
         if (rrset->getType() == RRType::CNAME()) {
             // XXX: this check will become incorrect when we support DNSSEC
             // (depending on how we support DNSSEC).  We should revisit it
@@ -168,7 +165,11 @@ struct MemoryZone::MemoryZoneImpl {
             domain = node->getData();
         }
 
-        // Checks related to the surrounding data
+        // Checks related to the surrounding data.
+        // Note: when the check fails and the exception is thrown, it may
+        // break strong exception guarantee.  At the moment we prefer
+        // code simplicity and don't bother to introduce complicated
+        // recovery code.
         contextCheck(rrset, domain);
 
         // Try inserting the rrset there
@@ -249,7 +250,7 @@ struct MemoryZone::MemoryZoneImpl {
             // a different way than described in 4.1 of that RFC,
             // but because of the assumption in section 3, it has the
             // same behaviour.
-            return true;
+            return (true);
         }
 
         // Look for NS




More information about the bind10-changes mailing list