mirror of
https://github.com/rakshasa/rtorrent.git
synced 2026-10-17 06:36:18 +00:00
* Use random, not rand, in rak::generate_random as the latter wasn't
being seeded. * Added a flag to PeerInfo for those that are in handshake, which is used by PeerList::connect_keep_handshake flag to decide if that address is to be re-added to the available list when there is already a connection in progress. This ensures that multiple ports on the same address don't end up discarded prematurely. git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@770 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
+1
-1
@@ -279,7 +279,7 @@ generate_random(size_t length) {
|
|||||||
Sequence s;
|
Sequence s;
|
||||||
s.reserve(length);
|
s.reserve(length);
|
||||||
|
|
||||||
std::generate_n(std::back_inserter(s), length, &std::rand);
|
std::generate_n(std::back_inserter(s), length, &::random);
|
||||||
|
|
||||||
return s;
|
return s;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user