mirror of
https://github.com/jwinterm/wownero.git
synced 2026-12-02 12:04:22 +01:00
s/terget/target/
This commit is contained in:
@@ -203,7 +203,7 @@ uint64_t connection_basic::get_rate_up_limit() {
|
||||
uint64_t limit;
|
||||
{
|
||||
CRITICAL_REGION_LOCAL( network_throttle_manager::m_lock_get_global_throttle_out );
|
||||
limit = network_throttle_manager::get_global_throttle_out().get_terget_speed();
|
||||
limit = network_throttle_manager::get_global_throttle_out().get_target_speed();
|
||||
}
|
||||
return limit;
|
||||
}
|
||||
@@ -212,7 +212,7 @@ uint64_t connection_basic::get_rate_down_limit() {
|
||||
uint64_t limit;
|
||||
{
|
||||
CRITICAL_REGION_LOCAL( network_throttle_manager::m_lock_get_global_throttle_in );
|
||||
limit = network_throttle_manager::get_global_throttle_in().get_terget_speed();
|
||||
limit = network_throttle_manager::get_global_throttle_in().get_target_speed();
|
||||
}
|
||||
return limit;
|
||||
}
|
||||
@@ -224,12 +224,12 @@ void connection_basic::save_limit_to_file(int limit) {
|
||||
|
||||
{
|
||||
CRITICAL_REGION_LOCAL( network_throttle_manager::m_lock_get_global_throttle_out );
|
||||
epee::net_utils::data_logger::get_instance().add_data("upload_limit", network_throttle_manager::get_global_throttle_out().get_terget_speed() / 1024);
|
||||
epee::net_utils::data_logger::get_instance().add_data("upload_limit", network_throttle_manager::get_global_throttle_out().get_target_speed() / 1024);
|
||||
}
|
||||
|
||||
{
|
||||
CRITICAL_REGION_LOCAL( network_throttle_manager::m_lock_get_global_throttle_in );
|
||||
epee::net_utils::data_logger::get_instance().add_data("download_limit", network_throttle_manager::get_global_throttle_in().get_terget_speed() / 1024);
|
||||
epee::net_utils::data_logger::get_instance().add_data("download_limit", network_throttle_manager::get_global_throttle_in().get_target_speed() / 1024);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -172,7 +172,7 @@ void network_throttle::set_real_target_speed( network_speed_kbps real_target )
|
||||
m_real_target_speed = real_target * 1024;
|
||||
}
|
||||
|
||||
network_speed_kbps network_throttle::get_terget_speed()
|
||||
network_speed_kbps network_throttle::get_target_speed()
|
||||
{
|
||||
return m_real_target_speed / 1024;
|
||||
}
|
||||
|
||||
@@ -81,7 +81,7 @@ class network_throttle : public i_network_throttle {
|
||||
virtual void set_name(const std::string &name);
|
||||
virtual void set_target_speed( network_speed_kbps target );
|
||||
virtual void set_real_target_speed( network_speed_kbps real_target ); // only for throttle_out
|
||||
virtual network_speed_kbps get_terget_speed();
|
||||
virtual network_speed_kbps get_target_speed();
|
||||
|
||||
// add information about events:
|
||||
virtual void handle_trafic_exact(size_t packet_size); ///< count the new traffic/packet; the size is exact considering all network costs
|
||||
|
||||
@@ -147,7 +147,7 @@ class i_network_throttle {
|
||||
virtual void set_name(const std::string &name)=0;
|
||||
virtual void set_target_speed( network_speed_kbps target )=0;
|
||||
virtual void set_real_target_speed(network_speed_kbps real_target)=0;
|
||||
virtual network_speed_kbps get_terget_speed()=0;
|
||||
virtual network_speed_kbps get_target_speed()=0;
|
||||
|
||||
virtual void handle_trafic_exact(size_t packet_size) =0; // count the new traffic/packet; the size is exact considering all network costs
|
||||
virtual void handle_trafic_tcp(size_t packet_size) =0; // count the new traffic/packet; the size is as TCP, we will consider MTU etc
|
||||
|
||||
Reference in New Issue
Block a user