about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2016-02-24T12·07+0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2016-02-24T12·07+0100
commitccdbf589a47b486876de28a9beab64360ba8b8fc (patch)
tree749c03e1b81069aa745d68e6d834ed3073b7164f
parent5f862658c3f8e518fb631d0536f2b38f107970e1 (diff)
C++ templates are just a glorified macro facility
-rw-r--r--src/libutil/pool.hh4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libutil/pool.hh b/src/libutil/pool.hh
index b75a3cbf854f..b9eb2dd1ecce 100644
--- a/src/libutil/pool.hh
+++ b/src/libutil/pool.hh
@@ -58,7 +58,7 @@ private:
 
 public:
 
-    Pool(size_t max = std::numeric_limits<size_t>::max,
+    Pool(size_t max = std::numeric_limits<size_t>::max(),
         const Factory & factory = []() { return make_ref<R>(); },
         const Validator & validator = [](ref<R> r) { return true; })
         : factory(factory)
@@ -144,7 +144,7 @@ public:
     unsigned int count()
     {
         auto state_(state.lock());
-        return state_->count + state_->inUse;
+        return state_->idle.size() + state_->inUse;
     }
 };