aboutsummaryrefslogtreecommitdiff
path: root/contrib/epee/include/net
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2016-03-11 20:15:10 +0200
committerRiccardo Spagni <ric@spagni.net>2016-03-11 20:15:10 +0200
commitdfd0e9c97d80c5cd7115d6cbb49cce08168071b6 (patch)
tree7bb5c56c18c83f3180101e310198cb3e3fdf1ab7 /contrib/epee/include/net
parentMerge pull request #711 (diff)
parentNeed to link boost::chrono in more places now (diff)
downloadmonero-dfd0e9c97d80c5cd7115d6cbb49cce08168071b6.tar.xz
Merge pull request #712
66c2fc7 Need to link boost::chrono in more places now (Howard Chu) b937a2c Use boost::thread instead of std::thread (Howard Chu)
Diffstat (limited to 'contrib/epee/include/net')
-rw-r--r--contrib/epee/include/net/abstract_tcp_server2.h6
-rw-r--r--contrib/epee/include/net/abstract_tcp_server2.inl4
2 files changed, 5 insertions, 5 deletions
diff --git a/contrib/epee/include/net/abstract_tcp_server2.h b/contrib/epee/include/net/abstract_tcp_server2.h
index f3dd7291c..80f3f6db0 100644
--- a/contrib/epee/include/net/abstract_tcp_server2.h
+++ b/contrib/epee/include/net/abstract_tcp_server2.h
@@ -153,8 +153,8 @@ namespace net_utils
// for calculate speed (last 60 sec)
network_throttle m_throttle_speed_in;
network_throttle m_throttle_speed_out;
- std::mutex m_throttle_speed_in_mutex;
- std::mutex m_throttle_speed_out_mutex;
+ boost::mutex m_throttle_speed_in_mutex;
+ boost::mutex m_throttle_speed_out_mutex;
public:
void setRpcStation();
@@ -307,7 +307,7 @@ namespace net_utils
/// The next connection to be accepted
connection_ptr new_connection_;
- std::mutex connections_mutex;
+ boost::mutex connections_mutex;
std::deque<std::pair<boost::system_time, connection_ptr>> connections_;
}; // class <>boosted_tcp_server
diff --git a/contrib/epee/include/net/abstract_tcp_server2.inl b/contrib/epee/include/net/abstract_tcp_server2.inl
index 4fb6fa75d..698e1947a 100644
--- a/contrib/epee/include/net/abstract_tcp_server2.inl
+++ b/contrib/epee/include/net/abstract_tcp_server2.inl
@@ -41,7 +41,7 @@
#include <boost/utility/value_init.hpp>
#include <boost/asio/deadline_timer.hpp>
#include <boost/date_time/posix_time/posix_time.hpp> // TODO
-#include <boost/thread/thread.hpp> // TODO
+#include <boost/thread/v2/thread.hpp> // TODO
#include "misc_language.h"
#include "pragma_comp_defs.h"
@@ -294,7 +294,7 @@ PRAGMA_WARNING_DISABLE_VS(4355)
if (delay > 0) {
long int ms = (long int)(delay * 100);
epee::net_utils::data_logger::get_instance().add_data("sleep_down", ms);
- std::this_thread::sleep_for(std::chrono::milliseconds(ms));
+ boost::this_thread::sleep_for(boost::chrono::milliseconds(ms));
}
} while(delay > 0);
} // any form of sleeping