BIND 10 master, updated. f37c712d3dc978323e629d9ee4e982f1ae7570ec Merge branch 'trac1968'

BIND 10 source code commits bind10-changes at lists.isc.org
Mon May 14 13:47:41 UTC 2012


The branch, master has been updated
       via  f37c712d3dc978323e629d9ee4e982f1ae7570ec (commit)
       via  57d30d529adbb49aaaba18f8347430a166d087d6 (commit)
       via  07eb75f4b57d4deb715cf806379b81723832f8c2 (commit)
       via  90a1b131d672d476cdc1dd30d32f1554f45f98ce (commit)
       via  35cf5f4b8fe9aed43d5374fd3829871d0d7a4c8f (commit)
       via  f3ff650b401bfe97f12554caa9ced91b431de5f1 (commit)
       via  dee64b333f7ec54a7647347679790b40f0c2b76b (commit)
      from  617bdac8b0f2222920e63faa65f5fcb5ac729054 (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 f37c712d3dc978323e629d9ee4e982f1ae7570ec
Merge: 57d30d529adbb49aaaba18f8347430a166d087d6 07eb75f4b57d4deb715cf806379b81723832f8c2
Author: Tomek Mrugalski <tomasz at isc.org>
Date:   Mon May 14 15:29:53 2012 +0200

    Merge branch 'trac1968'

commit 57d30d529adbb49aaaba18f8347430a166d087d6
Author: Tomek Mrugalski <tomasz at isc.org>
Date:   Mon May 14 15:29:29 2012 +0200

    Revert "[master] temporarily removed DHCP stuff from configure.ac, too."
    
    This reverts commit 617bdac8b0f2222920e63faa65f5fcb5ac729054.

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

Summary of changes:
 configure.ac                                       |   10 ++++++++--
 src/lib/dhcp/Makefile.am                           |    1 +
 src/lib/dhcp/iface_mgr.cc                          |    9 ---------
 src/lib/dhcp/iface_mgr_bsd.cc                      |    4 +++-
 src/lib/dhcp/iface_mgr_linux.cc                    |    1 -
 .../dhcp/{iface_mgr_bsd.cc => iface_mgr_sun.cc}    |    8 +++++---
 src/lib/dhcp/tests/Makefile.am                     |    1 +
 7 files changed, 18 insertions(+), 16 deletions(-)
 copy src/lib/dhcp/{iface_mgr_bsd.cc => iface_mgr_sun.cc} (91%)

-----------------------------------------------------------------------
diff --git a/configure.ac b/configure.ac
index e94e400..87a98f3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -407,9 +407,9 @@ case $system in
       OS_TYPE="BSD"
       CPPFLAGS="$CPPFLAGS -DOS_BSD"
       ;;
-    Solaris)
+    SunOS)
       OS_TYPE="Solaris"
-      CPPFLAGS="$CPPFLAGS -DOS_SOLARIS"
+      CPPFLAGS="$CPPFLAGS -DOS_SUN"
       ;;
     *)
       OS_TYPE="Unknown"
@@ -1012,6 +1012,10 @@ AC_CONFIG_FILES([Makefile
                  src/bin/auth/benchmarks/Makefile
                  src/bin/ddns/Makefile
                  src/bin/ddns/tests/Makefile
+                 src/bin/dhcp6/Makefile
+                 src/bin/dhcp6/tests/Makefile
+                 src/bin/dhcp4/Makefile
+                 src/bin/dhcp4/tests/Makefile
                  src/bin/resolver/Makefile
                  src/bin/resolver/tests/Makefile
                  src/bin/sockcreator/Makefile
@@ -1078,6 +1082,8 @@ AC_CONFIG_FILES([Makefile
                  src/lib/dns/python/Makefile
                  src/lib/dns/python/tests/Makefile
                  src/lib/dns/benchmarks/Makefile
+                 src/lib/dhcp/Makefile
+                 src/lib/dhcp/tests/Makefile
                  src/lib/exceptions/Makefile
                  src/lib/exceptions/tests/Makefile
                  src/lib/datasrc/Makefile
diff --git a/src/lib/dhcp/Makefile.am b/src/lib/dhcp/Makefile.am
index 5eada15..9d00911 100644
--- a/src/lib/dhcp/Makefile.am
+++ b/src/lib/dhcp/Makefile.am
@@ -13,6 +13,7 @@ libdhcp___la_SOURCES += libdhcp++.cc libdhcp++.h
 libdhcp___la_SOURCES += iface_mgr.cc iface_mgr.h
 libdhcp___la_SOURCES += iface_mgr_linux.cc
 libdhcp___la_SOURCES += iface_mgr_bsd.cc
+libdhcp___la_SOURCES += iface_mgr_sun.cc
 libdhcp___la_SOURCES += option.cc option.h
 libdhcp___la_SOURCES += option6_ia.cc option6_ia.h
 libdhcp___la_SOURCES += option6_iaaddr.cc option6_iaaddr.h
diff --git a/src/lib/dhcp/iface_mgr.cc b/src/lib/dhcp/iface_mgr.cc
index 990e987..1505fbf 100644
--- a/src/lib/dhcp/iface_mgr.cc
+++ b/src/lib/dhcp/iface_mgr.cc
@@ -213,15 +213,6 @@ void IfaceMgr::stubDetectIfaces() {
     }
 }
 
-/// @todo: Remove this once we have OS-specific interface detection
-/// routines (or at least OS-specific files, like iface_mgr_solaris.cc)
-/// for all OSes.
-#if !defined(OS_LINUX) && !defined(OS_BSD)
-void IfaceMgr::detectIfaces() {
-    stubDetectIfaces();
-}
-#endif
-
 bool IfaceMgr::openSockets4(const uint16_t port) {
     int sock;
     int count = 0;
diff --git a/src/lib/dhcp/iface_mgr_bsd.cc b/src/lib/dhcp/iface_mgr_bsd.cc
index aa6dd5b..e3f11a1 100644
--- a/src/lib/dhcp/iface_mgr_bsd.cc
+++ b/src/lib/dhcp/iface_mgr_bsd.cc
@@ -25,6 +25,7 @@ using namespace isc::asiolink;
 using namespace isc::dhcp;
 
 namespace isc {
+namespace dhcp {
 
 void
 IfaceMgr::detectIfaces() {
@@ -48,6 +49,7 @@ bool IfaceMgr::os_receive4(struct msghdr& /*m*/, Pkt4Ptr& /*pkt*/) {
   return (true); // pretend that we have everything set up for reception.
 }
 
-}
+} // end of isc::dhcp namespace
+} // end of dhcp namespace
 
 #endif
diff --git a/src/lib/dhcp/iface_mgr_linux.cc b/src/lib/dhcp/iface_mgr_linux.cc
index 3faac02..90431de 100644
--- a/src/lib/dhcp/iface_mgr_linux.cc
+++ b/src/lib/dhcp/iface_mgr_linux.cc
@@ -410,7 +410,6 @@ void Netlink::release_list(NetlinkMessages& messages) {
 } // end of anonymous namespace
 
 namespace isc {
-
 namespace dhcp {
 
 /// @brief Detect available interfaces on Linux systems.
diff --git a/src/lib/dhcp/iface_mgr_sun.cc b/src/lib/dhcp/iface_mgr_sun.cc
new file mode 100644
index 0000000..5847906
--- /dev/null
+++ b/src/lib/dhcp/iface_mgr_sun.cc
@@ -0,0 +1,55 @@
+// Copyright (C) 2011  Internet Systems Consortium, Inc. ("ISC")
+//
+// Permission to use, copy, modify, and/or distribute this software for any
+// purpose with or without fee is hereby granted, provided that the above
+// copyright notice and this permission notice appear in all copies.
+//
+// THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
+// REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
+// AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
+// INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
+// LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
+// OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+// PERFORMANCE OF THIS SOFTWARE.
+
+#include <config.h>
+
+#if defined(OS_SUN)
+
+#include <dhcp/iface_mgr.h>
+#include <exceptions/exceptions.h>
+
+using namespace std;
+using namespace isc;
+using namespace isc::asiolink;
+using namespace isc::dhcp;
+
+namespace isc {
+namespace dhcp {
+
+void
+IfaceMgr::detectIfaces() {
+    /// @todo do the actual detection on Solaris. Currently just calling
+    /// stub implementation.
+    stubDetectIfaces();
+}
+
+void IfaceMgr::os_send4(struct msghdr& /*m*/,
+                        boost::scoped_array<char>& /*control_buf*/,
+                        size_t /*control_buf_len*/,
+                        const Pkt4Ptr& /*pkt*/) {
+  // @todo: Are there any specific actions required before sending IPv4 packet
+  // on BSDs? See iface_mgr_linux.cc for working Linux implementation.
+}
+
+bool IfaceMgr::os_receive4(struct msghdr& /*m*/, Pkt4Ptr& /*pkt*/) {
+  // @todo: Are there any specific actions required before receiving IPv4 packet
+  // on BSDs? See iface_mgr_linux.cc for working Linux implementation.
+
+  return (true); // pretend that we have everything set up for reception.
+}
+
+} // end of isc::dhcp namespace
+} // end of dhcp namespace
+
+#endif
diff --git a/src/lib/dhcp/tests/Makefile.am b/src/lib/dhcp/tests/Makefile.am
index e86fa24..c68de01 100644
--- a/src/lib/dhcp/tests/Makefile.am
+++ b/src/lib/dhcp/tests/Makefile.am
@@ -23,6 +23,7 @@ libdhcp___unittests_SOURCES += libdhcp++_unittest.cc
 libdhcp___unittests_SOURCES += ../iface_mgr.cc ../iface_mgr.h iface_mgr_unittest.cc
 libdhcp___unittests_SOURCES += ../iface_mgr_linux.cc
 libdhcp___unittests_SOURCES += ../iface_mgr_bsd.cc
+libdhcp___unittests_SOURCES += ../iface_mgr_sun.cc
 libdhcp___unittests_SOURCES += ../option6_iaaddr.h ../option6_iaaddr.cc option6_iaaddr_unittest.cc
 libdhcp___unittests_SOURCES += ../option6_ia.h ../option6_ia.cc option6_ia_unittest.cc
 libdhcp___unittests_SOURCES += ../option6_addrlst.h ../option6_addrlst.cc option6_addrlst_unittest.cc



More information about the bind10-changes mailing list