diff --git a/common/include/eoskeygen/key_search.hpp b/common/include/eoskeygen/key_search.hpp index 902716f..b7fa5af 100644 --- a/common/include/eoskeygen/key_search.hpp +++ b/common/include/eoskeygen/key_search.hpp @@ -69,6 +69,8 @@ public : // Set the number of threads to use while searching. void setThreadCount(size_t num); + + size_t getThreadCount() const; #endif /* EOSIOKEYGEN_HAVE_THREADS */ // Aborts find() operation if started. diff --git a/common/src/key_search_mt.cpp b/common/src/key_search_mt.cpp index 8c1585b..b0773ba 100644 --- a/common/src/key_search_mt.cpp +++ b/common/src/key_search_mt.cpp @@ -73,6 +73,11 @@ size_t KeySearch::max_threads() return std::thread::hardware_concurrency(); } +size_t KeySearch::getThreadCount() const +{ + return m_threads; +} + void KeySearch::_search_mt() { std::vector t;