]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Refactored actions for comm_poll to Cache Manager singleton API.
authorFrancesco Chemolli <kinkie@squid-cache.org>
Wed, 9 Jul 2008 20:33:02 +0000 (22:33 +0200)
committerFrancesco Chemolli <kinkie@squid-cache.org>
Wed, 9 Jul 2008 20:33:02 +0000 (22:33 +0200)
src/comm_poll.cc
src/comm_poll.h
src/main.cc

index da2fc42c2a5b768b89d1e4cf1487a08462d04fe7..95e5084eaf89b89b84cc90f8dafca469655c5db4 100644 (file)
@@ -606,11 +606,12 @@ comm_select_init(void)
 {}
 
 void
-commPollRegisterWithCacheManager(CacheManager & manager)
+commPollRegisterWithCacheManager(void)
 {
-    manager.registerAction("comm_poll_incoming",
-                           "comm_incoming() stats",
-                           commIncomingStats, 0, 1);
+    CacheManager::GetInstance()->
+        registerAction("comm_poll_incoming",
+                       "comm_incoming() stats",
+                       commIncomingStats, 0, 1);
 }
 
 
index 3c0f69321ee53ffb19c3d837378f08711b8676d1..93f7b7a72fb4d7790bc3964d5aa44686990ec56c 100644 (file)
@@ -38,6 +38,6 @@
 
 class CacheManager;
 
-extern void commPollRegisterWithCacheManager(CacheManager & manager);
+extern void commPollRegisterWithCacheManager(void);
 
 #endif /* SQUID_COMM_POLL_H */
index 6b728a24754846f920068831a38cb4aedb0cb277..d8aeaa5a432c8e260b7bc88ac17e3eafe05a4503 100644 (file)
@@ -989,7 +989,7 @@ mainInitialize(void)
 #endif
 #ifdef USE_POLL
 
-        commPollRegisterWithCacheManager(*manager);
+        commPollRegisterWithCacheManager();
 #endif
 #if defined(USE_SELECT) || defined(USE_SELECT_WIN32)