BIND 10 trac1627, updated. 35c0f080ae896d1e146e942052ed2413b2e2b57a [1627] Fix type of exception thrown in testcase

BIND 10 source code commits bind10-changes at lists.isc.org
Thu Mar 29 22:10:16 UTC 2012


The branch, trac1627 has been updated
       via  35c0f080ae896d1e146e942052ed2413b2e2b57a (commit)
       via  56c86d6454930c260875b797367ab6680bbd1dd8 (commit)
      from  db81de14a1c0c6f1e1594920353eb1677cf19aea (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 35c0f080ae896d1e146e942052ed2413b2e2b57a
Author: Mukund Sivaraman <muks at isc.org>
Date:   Fri Mar 30 03:39:02 2012 +0530

    [1627] Fix type of exception thrown in testcase
    
    NameParserExceptions are now caught and AuthConfigError is thrown.

commit 56c86d6454930c260875b797367ab6680bbd1dd8
Author: Mukund Sivaraman <muks at isc.org>
Date:   Fri Mar 30 03:32:37 2012 +0530

    [1627] Rewrite code to use local variables

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

Summary of changes:
 src/bin/auth/auth_config.cc           |    5 ++---
 src/bin/auth/tests/config_unittest.cc |    2 +-
 2 files changed, 3 insertions(+), 4 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/bin/auth/auth_config.cc b/src/bin/auth/auth_config.cc
index e2961b4..69e66cf 100644
--- a/src/bin/auth/auth_config.cc
+++ b/src/bin/auth/auth_config.cc
@@ -168,8 +168,7 @@ MemoryDatasourceConfig::build(ConstElementPtr config_value) {
 
         InMemoryZoneFinder* imzf = NULL;
         try {
-            imzf = new InMemoryZoneFinder(rrclass_,
-                                          Name(origin->stringValue()));
+            imzf = new InMemoryZoneFinder(rrclass_, Name(origin_txt));
         } catch (const isc::dns::NameParserException& ex) {
             isc_throw(AuthConfigError, "unable to parse zone's origin: " <<
                       ex.what());
@@ -188,7 +187,7 @@ MemoryDatasourceConfig::build(ConstElementPtr config_value) {
          * need the load method to be split into some kind of build and
          * commit/abort parts.
          */
-        zone_finder->load(file->stringValue());
+        zone_finder->load(file_txt);
     }
 }
 
diff --git a/src/bin/auth/tests/config_unittest.cc b/src/bin/auth/tests/config_unittest.cc
index fb5067e..6fc4cef 100644
--- a/src/bin/auth/tests/config_unittest.cc
+++ b/src/bin/auth/tests/config_unittest.cc
@@ -332,7 +332,7 @@ TEST_F(MemoryDatasrcConfigTest, addBadZone) {
                       "[{\"type\": \"memory\","
                       "  \"zones\": [{\"origin\": \"example..com\","
                       "               \"file\": \"example.zone\"}]}]")),
-                 EmptyLabel);
+                 AuthConfigError);
 
     // bogus RR class name
     EXPECT_THROW(parser->build(



More information about the bind10-changes mailing list