Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/webtorrent/webtorrent.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorFeross Aboukhadijeh <feross@feross.org>2015-09-17 00:27:55 +0300
committerFeross Aboukhadijeh <feross@feross.org>2015-09-17 00:27:55 +0300
commit9e67ed772a05daec160f1bb05977b8f65cf83fd6 (patch)
tree55fcf841415e948b4ac95def7be610d9efd13ef4 /lib
parent5afdec34769248e672cafc7c73a12feedf73b9ec (diff)
standard
Diffstat (limited to 'lib')
-rw-r--r--lib/torrent.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/torrent.js b/lib/torrent.js
index 0275d70..6b58f77 100644
--- a/lib/torrent.js
+++ b/lib/torrent.js
@@ -796,7 +796,8 @@ Torrent.prototype._updateWire = function (wire) {
function validateWire () {
if (wire.requests.length) return
- for (var i = self._selections.length; i--;) {
+ var i = self._selections.length
+ while (i--) {
var next = self._selections[i]
var piece
if (self.strategy === 'rarest') {