Author: johnnyg
Revision: 6064
Log:
Fix torrent info name not being utf-8 decoded when root file/folder
name is blank
Diff:
Modified: branches/1.2_RC/ChangeLog
===================================================================
--- branches/1.2_RC/ChangeLog 2009-12-25 21:33:01 UTC (rev 6063)
+++ branches/1.2_RC/ChangeLog 2009-12-26 17:09:05 UTC (rev 6064)
@@ -6,6 +6,8 @@
* Change share ratio calculation to use the total done instead of the
all time
downloaded value. This change will make the share ratio calculation
not
use data downloaded in failed hash checks.
+ * Fix torrent info name not being utf-8 decoded when root file/folder
name
+ is blank
==== GtkUI ====
* Fix #1104, #735 use path.utf-8 if available
Modified: branches/1.2_RC/deluge/core/torrent.py
===================================================================
--- branches/1.2_RC/deluge/core/torrent.py 2009-12-25 21:33:01 UTC (rev
6063)
+++ branches/1.2_RC/deluge/core/torrent.py 2009-12-26 17:09:05 UTC (rev
6064)
@@ -603,7 +603,7 @@
if self.handle.has_metadata():
name = self.torrent_info.file_at(0).path.split("/", 1)[0]
if not name:
- return self.torrent_info.name()
+ name = self.torrent_info.name()
try:
return name.decode("utf8", "ignore")
except UnicodeDecodeError:
Modified: trunk/deluge/core/torrent.py
===================================================================
--- trunk/deluge/core/torrent.py 2009-12-25 21:33:01 UTC (rev 6063)
+++ trunk/deluge/core/torrent.py 2009-12-26 17:09:05 UTC (rev 6064)
@@ -603,7 +603,7 @@
if self.handle.has_metadata():
name = self.torrent_info.file_at(0).path.split("/", 1)[0]
if not name:
- return self.torrent_info.name()
+ name = self.torrent_info.name()
try:
return name.decode("utf8", "ignore")
except UnicodeDecodeError:
--
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.