Fix torrent VFS: announce sublist can be empty
authorOleg Broytman <phd@phdru.name>
Mon, 4 Jul 2016 15:24:51 +0000 (18:24 +0300)
committerOleg Broytman <phd@phdru.name>
Mon, 4 Jul 2016 15:27:13 +0000 (18:27 +0300)
torrent

diff --git a/torrent b/torrent
index 1dccb65..ebc3ee2 100755 (executable)
--- a/torrent
+++ b/torrent
@@ -35,9 +35,9 @@ The filesystem is, naturally, read-only.
 
 """
 
-__version__ = "1.2.3"
+__version__ = "1.2.4"
 __author__ = "Oleg Broytman <phd@phdru.name>"
-__copyright__ = "Copyright (C) 2010-2015 PhiloSoft Design"
+__copyright__ = "Copyright (C) 2010-2016 PhiloSoft Design"
 __license__ = "GPL"
 
 
@@ -308,7 +308,7 @@ def decode_datetime(dt):
 
 
 def decode_announce_list(announce):
-    return '\n'.join(l[0] for l in announce)
+    return '\n'.join(l[0] for l in announce if l)
 
 
 command = sys.argv[1]