From: Francesco Chemolli Date: Wed, 9 Jul 2008 20:20:14 +0000 (+0200) Subject: Refactored actions for "carp" to Cache Manager singleton API. X-Git-Tag: SQUID_3_1_0_1~49^2~143^2~33 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1b8a5f51075c6e103963ebec03736f422c09e27b;p=thirdparty%2Fsquid.git Refactored actions for "carp" to Cache Manager singleton API. --- diff --git a/src/carp.cc b/src/carp.cc index 9c7fa65324..da7679b988 100644 --- a/src/carp.cc +++ b/src/carp.cc @@ -153,9 +153,10 @@ carpInit(void) } void -carpRegisterWithCacheManager(CacheManager & manager) +carpRegisterWithCacheManager() { - manager.registerAction("carp", "CARP information", carpCachemgr, 0, 1); + CacheManager::GetInstance()-> + registerAction("carp", "CARP information", carpCachemgr, 0, 1); } peer * diff --git a/src/main.cc b/src/main.cc index d2b78e9abb..72947fa6fb 100644 --- a/src/main.cc +++ b/src/main.cc @@ -972,7 +972,7 @@ mainInitialize(void) authenticateRegisterWithCacheManager(&Config.authConfiguration); #if USE_CARP - carpRegisterWithCacheManager(*manager); + carpRegisterWithCacheManager(); #endif cbdataRegisterWithCacheManager(*manager); diff --git a/src/protos.h b/src/protos.h index a5362ee30f..ceba7c908b 100644 --- a/src/protos.h +++ b/src/protos.h @@ -730,7 +730,7 @@ SQUIDCEXTERN int internalHostnameIs(const char *); #if USE_CARP SQUIDCEXTERN void carpInit(void); -extern void carpRegisterWithCacheManager(CacheManager & manager); +extern void carpRegisterWithCacheManager(); SQUIDCEXTERN peer *carpSelectParent(HttpRequest *); #endif