diff --git a/ChangeLog b/ChangeLog index 6965e391d..6bc87b7f4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,5 @@ + * fixed piece sorting bug of deadline pieces * fixed python binding build on Mac OS and BSD * fixed UNC path normalization (on windows, unless UNC paths are disabled) * fixed possible crash when enabling multiple connections per IP diff --git a/src/torrent.cpp b/src/torrent.cpp index b9d4ace10..ac799cff5 100644 --- a/src/torrent.cpp +++ b/src/torrent.cpp @@ -3654,7 +3654,7 @@ namespace libtorrent } while (i != m_time_critical_pieces.begin() && i->deadline < boost::prior(i)->deadline) { - std::iter_swap(i, boost::next(i)); + std::iter_swap(i, boost::prior(i)); --i; } return;