]> git.ipfire.org Git - thirdparty/squid.git/blobdiff - src/comm_select_win32.cc
Cleanup: zap CVS Id tags
[thirdparty/squid.git] / src / comm_select_win32.cc
index a09ea5e160002d03170ec5027f6d9f71872dd31f..041fa4e3ce50d6df5136ffa5008df7d17f51f9c2 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: comm_select_win32.cc,v 1.8 2008/02/24 12:59:08 serassio Exp $
+ * $Id$
  *
  * DEBUG: section 5     Socket Functions
  *
  *  it under the terms of the GNU General Public License as published by
  *  the Free Software Foundation; either version 2 of the License, or
  *  (at your option) any later version.
- *  
+ *
  *  This program is distributed in the hope that it will be useful,
  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  *  GNU General Public License for more details.
- *  
+ *
  *  You should have received a copy of the GNU General Public License
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
@@ -79,7 +79,7 @@ static int nwritefds;
  * of incoming ICP, then we need to check these sockets more than
  * if we just have HTTP.
  *
- * The variables 'incoming_icp_interval' and 'incoming_http_interval' 
+ * The variables 'incoming_icp_interval' and 'incoming_http_interval'
  * determine how many normal I/O events to process before checking
  * incoming sockets again.  Note we store the incoming_interval
  * multipled by a factor of (2^INCOMING_FACTOR) to have some
@@ -100,7 +100,7 @@ static int nwritefds;
  *  incoming_interval = incoming_interval + target_average - number_of_events_processed
  *
  * There are separate incoming_interval counters for both HTTP and ICP events
- * 
+ *
  * You can see the current values of the incoming_interval's, as well as
  * a histogram of 'incoming_events' by asking the cache manager
  * for 'comm_incoming', e.g.:
@@ -676,6 +676,15 @@ comm_select_dns_incoming(void)
     statHistCount(&statCounter.comm_dns_incoming, nevents);
 }
 
+static void
+commSelectRegisterWithCacheManager(void)
+{
+    CacheManager::GetInstance()->
+    registerAction("comm_select_incoming",
+                   "comm_incoming() stats",
+                   commIncomingStats, 0, 1);
+}
+
 void
 comm_select_init(void)
 {
@@ -684,14 +693,8 @@ comm_select_init(void)
     FD_ZERO(&global_readfds);
     FD_ZERO(&global_writefds);
     nreadfds = nwritefds = 0;
-}
 
-void
-commSelectRegisterWithCacheManager(CacheManager & manager)
-{
-    manager.registerAction("comm_select_incoming",
-                           "comm_incoming() stats",
-                           commIncomingStats, 0, 1);
+    commSelectRegisterWithCacheManager();
 }
 
 /*
@@ -701,7 +704,7 @@ commSelectRegisterWithCacheManager(CacheManager & manager)
  * and the server side of a cache fetch simultaneoulsy abort the
  * connection.  While I haven't really studied the code to figure out how
  * it happens, the snippet below may prevent the cache from exitting:
- * 
+ *
  * Call this from where the select loop fails.
  */
 static int
@@ -751,7 +754,7 @@ examine_select(fd_set * readfds, fd_set * writefds)
             commCallCloseHandlers(fd);
         } else if (F->timeoutHandler != NULL) {
             debugs(5, 0, "examine_select: Calling Timeout Handler");
-           ScheduleCallHere(F->timeoutHandler);
+            ScheduleCallHere(F->timeoutHandler);
         }
 
         F->closeHandler = NULL;