From 96f25d69420ef426b52266478ecbaf640616c775 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Sun, 25 May 2014 05:10:30 +0000 Subject: [PATCH] attempt to fix linux build --- src/kademlia/traversal_algorithm.cpp | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/kademlia/traversal_algorithm.cpp b/src/kademlia/traversal_algorithm.cpp index 78c249f94..a2f3d65eb 100644 --- a/src/kademlia/traversal_algorithm.cpp +++ b/src/kademlia/traversal_algorithm.cpp @@ -42,6 +42,19 @@ POSSIBILITY OF SUCH DAMAGE. #include "libtorrent/broadcast_socket.hpp" // for cidr_distance #include // for read_*_endpoint +#include + +namespace libtorrent { namespace dht +{ +#ifdef TORRENT_DHT_VERBOSE_LOGGING +TORRENT_DEFINE_LOG(traversal) +#endif + +using detail::read_v4_endpoint; +#if TORRENT_USE_IPV6 +using detail::read_v6_endpoint; +#endif + #if TORRENT_USE_ASSERTS template bool is_sorted(It b, It e, Cmp cmp) @@ -60,19 +73,6 @@ bool is_sorted(It b, It e, Cmp cmp) } #endif -#include - -namespace libtorrent { namespace dht -{ -#ifdef TORRENT_DHT_VERBOSE_LOGGING -TORRENT_DEFINE_LOG(traversal) -#endif - -using detail::read_v4_endpoint; -#if TORRENT_USE_IPV6 -using detail::read_v6_endpoint; -#endif - observer_ptr traversal_algorithm::new_observer(void* ptr , udp::endpoint const& ep, node_id const& id) { @@ -153,7 +153,7 @@ void traversal_algorithm::add_entry(node_id const& id, udp::endpoint addr, unsig o->flags |= flags; - TORRENT_ASSERT(is_sorted(m_results.begin(), m_results.end() + TORRENT_ASSERT(libtorrent::dht::is_sorted(m_results.begin(), m_results.end() , boost::bind( compare_ref , boost::bind(&observer::id, _1)