BIND 10 trac3315, updated. fba33a4f336010b0af70ba5c194d8850adf82485 [3315] Changes after second review:

BIND 10 source code commits bind10-changes at lists.isc.org
Tue Feb 4 14:17:07 UTC 2014


The branch, trac3315 has been updated
       via  fba33a4f336010b0af70ba5c194d8850adf82485 (commit)
      from  8d6bd774155061530c7c6cd0029332b0d35fe1ce (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 fba33a4f336010b0af70ba5c194d8850adf82485
Author: Tomek Mrugalski <tomasz at isc.org>
Date:   Tue Feb 4 15:16:52 2014 +0100

    [3315] Changes after second review:
    
     - SocketCallbackContainer is now SocketCallbackInfoContainer
     - test callback is now quiet

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

Summary of changes:
 src/lib/dhcp/iface_mgr.cc                |   12 ++++++------
 src/lib/dhcp/iface_mgr.h                 |    4 ++--
 src/lib/dhcp/tests/iface_mgr_unittest.cc |    1 -
 3 files changed, 8 insertions(+), 9 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/lib/dhcp/iface_mgr.cc b/src/lib/dhcp/iface_mgr.cc
index 64892b5..6a59124 100644
--- a/src/lib/dhcp/iface_mgr.cc
+++ b/src/lib/dhcp/iface_mgr.cc
@@ -228,7 +228,7 @@ IfaceMgr::isDirectResponseSupported() const {
 
 void
 IfaceMgr::addExternalSocket(int socketfd, SocketCallback callback) {
-    for (SocketCallbackContainer::iterator s = callbacks_.begin();
+    for (SocketCallbackInfoContainer::iterator s = callbacks_.begin();
          s != callbacks_.end(); ++s) {
 
         // There's such a socket description there already.
@@ -248,7 +248,7 @@ IfaceMgr::addExternalSocket(int socketfd, SocketCallback callback) {
 
 void
 IfaceMgr::deleteExternalSocket(int socketfd) {
-    for (SocketCallbackContainer::iterator s = callbacks_.begin();
+    for (SocketCallbackInfoContainer::iterator s = callbacks_.begin();
          s != callbacks_.end(); ++s) {
         if (s->socket_ == socketfd) {
             callbacks_.erase(s);
@@ -845,7 +845,7 @@ IfaceMgr::receive4(uint32_t timeout_sec, uint32_t timeout_usec /* = 0 */) {
 
     // if there are any callbacks for external sockets registered...
     if (!callbacks_.empty()) {
-        for (SocketCallbackContainer::const_iterator s = callbacks_.begin();
+        for (SocketCallbackInfoContainer::const_iterator s = callbacks_.begin();
              s != callbacks_.end(); ++s) {
             FD_SET(s->socket_, &sockets);
             if (maxfd < s->socket_) {
@@ -868,7 +868,7 @@ IfaceMgr::receive4(uint32_t timeout_sec, uint32_t timeout_usec /* = 0 */) {
     }
 
     // Let's find out which socket has the data
-    for (SocketCallbackContainer::iterator s = callbacks_.begin();
+    for (SocketCallbackInfoContainer::iterator s = callbacks_.begin();
          s != callbacks_.end(); ++s) {
         if (!FD_ISSET(s->socket_, &sockets)) {
             continue;
@@ -946,7 +946,7 @@ Pkt6Ptr IfaceMgr::receive6(uint32_t timeout_sec, uint32_t timeout_usec /* = 0 */
 
     // if there are any callbacks for external sockets registered...
     if (!callbacks_.empty()) {
-        for (SocketCallbackContainer::const_iterator s = callbacks_.begin();
+        for (SocketCallbackInfoContainer::const_iterator s = callbacks_.begin();
              s != callbacks_.end(); ++s) {
 
             // Add it to the set as well
@@ -971,7 +971,7 @@ Pkt6Ptr IfaceMgr::receive6(uint32_t timeout_sec, uint32_t timeout_usec /* = 0 */
     }
 
     // Let's find out which socket has the data
-    for (SocketCallbackContainer::iterator s = callbacks_.begin();
+    for (SocketCallbackInfoContainer::iterator s = callbacks_.begin();
          s != callbacks_.end(); ++s) {
         if (!FD_ISSET(s->socket_, &sockets)) {
             continue;
diff --git a/src/lib/dhcp/iface_mgr.h b/src/lib/dhcp/iface_mgr.h
index 268cc9f..12212c7 100644
--- a/src/lib/dhcp/iface_mgr.h
+++ b/src/lib/dhcp/iface_mgr.h
@@ -407,7 +407,7 @@ public:
     };
 
     /// Defines storage container for callbacks for external sockets
-    typedef std::list<SocketCallbackInfo> SocketCallbackContainer;
+    typedef std::list<SocketCallbackInfo> SocketCallbackInfoContainer;
 
     /// @brief Packet reception buffer size
     ///
@@ -1047,7 +1047,7 @@ private:
     PktFilter6Ptr packet_filter6_;
 
     /// @brief Contains list of callbacks for external sockets
-    SocketCallbackContainer callbacks_;
+    SocketCallbackInfoContainer callbacks_;
 };
 
 }; // namespace isc::dhcp
diff --git a/src/lib/dhcp/tests/iface_mgr_unittest.cc b/src/lib/dhcp/tests/iface_mgr_unittest.cc
index a8cb0cd..c2582da 100644
--- a/src/lib/dhcp/tests/iface_mgr_unittest.cc
+++ b/src/lib/dhcp/tests/iface_mgr_unittest.cc
@@ -2593,7 +2593,6 @@ volatile bool callback_ok;
 volatile bool callback2_ok;
 
 void my_callback(void) {
-    cout << "Callback triggered." << endl;
     callback_ok = true;
 }
 



More information about the bind10-changes mailing list