Author: andar

Revision: 5304

Log:
        Fix not using the encoding used in the torrent file to decode some 
strings

Diff:
Modified: branches/1.1.0_RC/deluge/ui/common.py
===================================================================
--- branches/1.1.0_RC/deluge/ui/common.py       2009-05-21 20:59:03 UTC (rev 
5303)
+++ branches/1.1.0_RC/deluge/ui/common.py       2009-05-25 02:27:33 UTC (rev 
5304)
@@ -100,7 +100,7 @@
 
             for f in self.__m_metadata["info"]["files"]:
                 self.__m_files.append({
-                    'path': decode_string(os.path.join(prefix, 
decode_string(os.path.join(*f["path"])))),
+                    'path': decode_string(os.path.join(prefix, 
decode_string(os.path.join(*f["path"]), self.encoding)), self.encoding),
                     'size': f["length"],
                     'download': True
                 })

Modified: trunk/deluge/ui/common.py
===================================================================
--- trunk/deluge/ui/common.py   2009-05-21 20:59:03 UTC (rev 5303)
+++ trunk/deluge/ui/common.py   2009-05-25 02:27:33 UTC (rev 5304)
@@ -102,7 +102,7 @@
                 prefix = self.__m_name
 
             for index, f in enumerate(self.__m_metadata["info"]["files"]):
-                path = decode_string(os.path.join(prefix, 
decode_string(os.path.join(*f["path"]))))
+                path = decode_string(os.path.join(prefix, 
decode_string(os.path.join(*f["path"]), self.encoding)), self.encoding)
                 f["index"] = index
                 paths[path] = f
 
@@ -127,7 +127,7 @@
 
             for f in self.__m_metadata["info"]["files"]:
                 self.__m_files.append({
-                    'path': decode_string(os.path.join(prefix, 
decode_string(os.path.join(*f["path"])))),
+                    'path': decode_string(os.path.join(prefix, 
decode_string(os.path.join(*f["path"]), self.encoding)), self.encoding),
                     'size': f["length"],
                     'download': True
                 })



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"deluge-commit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/deluge-commit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to