]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Remove memPoolInUseCount() wrapper
authorAmos Jeffries <squid3@treenet.co.nz>
Tue, 29 Mar 2016 08:00:44 +0000 (21:00 +1300)
committerAmos Jeffries <squid3@treenet.co.nz>
Tue, 29 Mar 2016 08:00:44 +0000 (21:00 +1300)
src/mem/AllocatorProxy.cc
src/mem/Pool.cc
src/mem/Pool.h
src/mem/old_api.cc
src/tests/stub_libmem.cc

index 9df8e83664f09a677dc00204a5d9153a8b2a23e0..9d5f7dcae4c10e3ccbce12a352f3c6c39d40d1c1 100644 (file)
@@ -41,7 +41,7 @@ Mem::AllocatorProxy::inUseCount() const
     if (!theAllocator)
         return 0;
     else
-        return memPoolInUseCount(theAllocator);
+        return theAllocator->inUseCount();
 }
 
 void
index 4db5fe78412e282eefde35bf8c1a0ad1560f66e0..42e2e9b1b54684c045a71531d3d44bf3c2367eed 100644 (file)
@@ -300,12 +300,6 @@ size_t MemAllocator::RoundedSize(size_t s)
     return ((s + sizeof(void*) - 1) / sizeof(void*)) * sizeof(void*);
 }
 
-int
-memPoolInUseCount(MemAllocator * pool)
-{
-    return pool->inUseCount();
-}
-
 int
 memPoolsTotalAllocated(void)
 {
index 8bcfd213c2b6330d66d83c5577fbdf7663f7f1a0..46ffb4d1c16fbabd3994bfddb19ba9ad44413595 100644 (file)
@@ -355,8 +355,6 @@ extern void memPoolIterateDone(MemPoolIterator ** iter);
  */
 extern int memPoolGetGlobalStats(MemPoolGlobalStats * stats);
 
-/// \ingroup MemPoolsAPI
-extern int memPoolInUseCount(MemAllocator *);
 /// \ingroup MemPoolsAPI
 extern int memPoolsTotalAllocated(void);
 
index 40c0d0b0af4cad60b2d6d49017f422b3aa8cef0e..9ccf60220c69c9fba0b2b47b969dabc9dd569344 100644 (file)
@@ -257,7 +257,7 @@ memStringCount()
     size_t result = 0;
 
     for (int counter = 0; counter < mem_str_pool_count; ++counter)
-        result += memPoolInUseCount(GetStrPool(counter));
+        result += GetStrPool(counter)->inUseCount();
 
     return result;
 }
@@ -513,7 +513,7 @@ memClean(void)
 int
 memInUse(mem_type type)
 {
-    return memPoolInUseCount(GetPool(type));
+    return GetPool(type)->inUseCount();
 }
 
 /* ick */
index f6a4a12ab17e19412bd42af63e4135c039b798b4..cb2c6efc89d6e0007457196eb013ed0d7335d9e2 100644 (file)
@@ -105,6 +105,5 @@ MemPoolIterator * memPoolIterate(void) STUB_RETVAL(NULL)
 MemImplementingAllocator * memPoolIterateNext(MemPoolIterator * iter) STUB_RETVAL(NULL)
 void memPoolIterateDone(MemPoolIterator ** iter) STUB
 int memPoolGetGlobalStats(MemPoolGlobalStats * stats) STUB_RETVAL(0)
-int memPoolInUseCount(MemAllocator *) STUB_RETVAL(0)
 int memPoolsTotalAllocated(void) STUB_RETVAL(0)