using std:: for integral types
This commit is contained in:
parent
335beb4bb1
commit
4c487ec47c
|
@ -1570,7 +1570,7 @@ namespace libtorrent
|
||||||
|
|
||||||
// this is the number of peers that are seeds, and count against
|
// this is the number of peers that are seeds, and count against
|
||||||
// m_num_seeds, but have not yet been connected
|
// m_num_seeds, but have not yet been connected
|
||||||
boost::uint16_t m_num_connecting_seeds = 0;
|
std::uint16_t m_num_connecting_seeds = 0;
|
||||||
|
|
||||||
// the timestamp of the last byte uploaded from this torrent specified in
|
// the timestamp of the last byte uploaded from this torrent specified in
|
||||||
// session_time. This is signed because it must be able to represent time
|
// session_time. This is signed because it must be able to represent time
|
||||||
|
|
|
@ -5018,7 +5018,7 @@ namespace libtorrent
|
||||||
// only add new piece-chunks if the send buffer is small enough
|
// only add new piece-chunks if the send buffer is small enough
|
||||||
// otherwise there will be no end to how large it will be!
|
// otherwise there will be no end to how large it will be!
|
||||||
|
|
||||||
int buffer_size_watermark = int(boost::int64_t(m_uploaded_last_second)
|
int buffer_size_watermark = int(std::int64_t(m_uploaded_last_second)
|
||||||
* m_settings.get_int(settings_pack::send_buffer_watermark_factor) / 100);
|
* m_settings.get_int(settings_pack::send_buffer_watermark_factor) / 100);
|
||||||
|
|
||||||
if (buffer_size_watermark < m_settings.get_int(settings_pack::send_buffer_low_watermark))
|
if (buffer_size_watermark < m_settings.get_int(settings_pack::send_buffer_low_watermark))
|
||||||
|
|
|
@ -673,8 +673,8 @@ namespace libtorrent
|
||||||
{
|
{
|
||||||
case string_type_base:
|
case string_type_base:
|
||||||
{
|
{
|
||||||
std::pair<boost::uint16_t, std::string> v(name, std::string());
|
std::pair<std::uint16_t, std::string> v(name, std::string());
|
||||||
std::vector<std::pair<boost::uint16_t, std::string> >::iterator i
|
std::vector<std::pair<std::uint16_t, std::string> >::iterator i
|
||||||
= std::lower_bound(m_strings.begin(), m_strings.end(), v
|
= std::lower_bound(m_strings.begin(), m_strings.end(), v
|
||||||
, &compare_first<std::string>);
|
, &compare_first<std::string>);
|
||||||
if (i != m_strings.end() && i->first == name) m_strings.erase(i);
|
if (i != m_strings.end() && i->first == name) m_strings.erase(i);
|
||||||
|
@ -682,8 +682,8 @@ namespace libtorrent
|
||||||
}
|
}
|
||||||
case int_type_base:
|
case int_type_base:
|
||||||
{
|
{
|
||||||
std::pair<boost::uint16_t, int> v(name, 0);
|
std::pair<std::uint16_t, int> v(name, 0);
|
||||||
std::vector<std::pair<boost::uint16_t, int> >::iterator i
|
std::vector<std::pair<std::uint16_t, int> >::iterator i
|
||||||
= std::lower_bound(m_ints.begin(), m_ints.end(), v
|
= std::lower_bound(m_ints.begin(), m_ints.end(), v
|
||||||
, &compare_first<int>);
|
, &compare_first<int>);
|
||||||
if (i != m_ints.end() && i->first == name) m_ints.erase(i);
|
if (i != m_ints.end() && i->first == name) m_ints.erase(i);
|
||||||
|
@ -691,8 +691,8 @@ namespace libtorrent
|
||||||
}
|
}
|
||||||
case bool_type_base:
|
case bool_type_base:
|
||||||
{
|
{
|
||||||
std::pair<boost::uint16_t, bool> v(name, false);
|
std::pair<std::uint16_t, bool> v(name, false);
|
||||||
std::vector<std::pair<boost::uint16_t, bool> >::iterator i
|
std::vector<std::pair<std::uint16_t, bool> >::iterator i
|
||||||
= std::lower_bound(m_bools.begin(), m_bools.end(), v
|
= std::lower_bound(m_bools.begin(), m_bools.end(), v
|
||||||
, &compare_first<bool>);
|
, &compare_first<bool>);
|
||||||
if (i != m_bools.end() && i->first == name) m_bools.erase(i);
|
if (i != m_bools.end() && i->first == name) m_bools.erase(i);
|
||||||
|
|
Loading…
Reference in New Issue