diff --git a/include/opendht/network_engine.h b/include/opendht/network_engine.h index 179ff9dd..ae42ca82 100644 --- a/include/opendht/network_engine.h +++ b/include/opendht/network_engine.h @@ -374,7 +374,7 @@ private: /* TODO */ static const std::string my_v; - bool rateLimit(const SockAddr& addr); + bool rateLimit(); static bool isMartian(const SockAddr& addr); bool isNodeBlacklisted(const SockAddr& addr) const; diff --git a/src/network_engine.cpp b/src/network_engine.cpp index 55ad78f2..72cb9447 100644 --- a/src/network_engine.cpp +++ b/src/network_engine.cpp @@ -295,7 +295,7 @@ NetworkEngine::processMessage(const uint8_t *buf, size_t buflen, const SockAddr& if (msg.type > MessageType::Reply) { /* Rate limit requests. */ - if (!rateLimit(from)) { + if (!rateLimit()) { DHT_LOG.WARN("Dropping request due to rate limiting."); return; }