* Console: Hide iframe on mobile browsers

* DataHelper: Speed up eq() (Ticket #437)
    * HTTPServer: Strip inbound X-Accept-Encoding header
    * netdb.jsp: HTML fixes
    * Plugins: Log error when console server not found
    * Reseed: Log tweak
This commit is contained in:
zzz
2011-04-10 18:22:43 +00:00
parent 960f12d66c
commit 428db02274
9 changed files with 57 additions and 24 deletions

View File

@ -111,6 +111,9 @@ public class Storage
lengthsList.add(Long.valueOf(length));
}
if (total <= 0)
throw new IOException("Torrent contains no data");
int pc_size = MIN_PIECE_SIZE;
int pcs = (int) ((total - 1)/pc_size) + 1;
while (pcs > MAX_PIECES && pc_size < MAX_PIECE_SIZE)