diff --git a/src/tcp_server.h b/src/tcp_server.h index bc37512..c0d903b 100644 --- a/src/tcp_server.h +++ b/src/tcp_server.h @@ -170,7 +170,11 @@ protected: uv_loop_t m_loop; +#ifdef P2POOL_DEBUGGING static void check_event_loop_thread(const char *func); +#else + static FORCEINLINE void check_event_loop_thread(const char*) {} +#endif std::vector m_preallocatedClients; diff --git a/src/tcp_server.inl b/src/tcp_server.inl index f83c55d..942d3a5 100644 --- a/src/tcp_server.inl +++ b/src/tcp_server.inl @@ -367,6 +367,7 @@ bool TCPServer::connect_to_peer(Client* client) return true; } +#ifdef P2POOL_DEBUGGING template void TCPServer::check_event_loop_thread(const char* func) { @@ -374,6 +375,7 @@ void TCPServer::check_event_loop_thread(const cha LOGERR(1, func << " called from another thread, this is not thread safe"); } } +#endif template void TCPServer::close_sockets(bool listen_sockets)