]> git.phdru.name Git - extfs.d.git/commitdiff
Fixed minor bugs
authorOleg Broytman <phd@phdru.name>
Sun, 9 Jun 2013 20:46:00 +0000 (20:46 +0000)
committerOleg Broytman <phd@phdru.name>
Sun, 9 Jun 2013 20:46:00 +0000 (20:46 +0000)
git-svn-id: file:///home/phd/archive/SVN/mc-extfs/trunk@60 1a6e6372-1aea-0310-bd00-dc960550e1df

torrent

diff --git a/torrent b/torrent
index 309aada9421ffa9b9f7605c6e84c1945fba78a2b..0aec962196e5f680dfeda399c7f19bbd3f260fd6 100755 (executable)
--- a/torrent
+++ b/torrent
@@ -65,7 +65,7 @@ def mctorrent_list():
         torrent_error('Info absent')
 
     info = torrent['info']
-    if 'name' not in info or 'name.utf-8' not in info:
+    if 'name' not in info and 'name.utf-8' not in info:
         torrent_error('Unknown name')
 
     codepage = torrent.get('codepage', None)
@@ -80,7 +80,7 @@ def mctorrent_list():
         files = info['files']
         paths = []
         for file in files:
-            if 'path' not in file or 'path.utf-8' not in file:
+            if 'path' not in file and 'path.utf-8' not in file:
                 torrent_error('Unknown path')
             if 'length' not in file:
                 torrent_error('Unknown length')