forked from premiere/premiere-libtorrent
more use of std::tuple_size<> and empty()
This commit is contained in:
parent
1075ae3b8d
commit
5db597c8b3
|
@ -63,10 +63,10 @@ namespace detail {
|
||||||
TORRENT_UNUSED(p);
|
TORRENT_UNUSED(p);
|
||||||
#if TORRENT_USE_IPV6
|
#if TORRENT_USE_IPV6
|
||||||
if (p == Proto::v6())
|
if (p == Proto::v6())
|
||||||
return address_v6::bytes_type().size();
|
return std::tuple_size<address_v6::bytes_type>::value;
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
return address_v4::bytes_type().size();
|
return std::tuple_size<address_v4::bytes_type>::value;
|
||||||
}
|
}
|
||||||
|
|
||||||
template<class OutIt>
|
template<class OutIt>
|
||||||
|
|
|
@ -684,7 +684,7 @@ namespace libtorrent {
|
||||||
branch.assign(leaf.data(), leaf.size());
|
branch.assign(leaf.data(), leaf.size());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (leaf.size() == 0) return;
|
if (leaf.empty()) return;
|
||||||
|
|
||||||
#if defined(TORRENT_WINDOWS) || defined(TORRENT_OS2)
|
#if defined(TORRENT_WINDOWS) || defined(TORRENT_OS2)
|
||||||
#define TORRENT_SEPARATOR_CHAR '\\'
|
#define TORRENT_SEPARATOR_CHAR '\\'
|
||||||
|
@ -910,4 +910,3 @@ namespace libtorrent {
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue