From 532b409a54dd547a83e62bbc10a749a3dda303df Mon Sep 17 00:00:00 2001 From: Andrew Resch Date: Fri, 14 Sep 2012 15:55:28 -0700 Subject: [PATCH] Only convert the move path to unicode if on windows --- deluge/core/torrent.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/deluge/core/torrent.py b/deluge/core/torrent.py index 68e09a86f..681a76489 100644 --- a/deluge/core/torrent.py +++ b/deluge/core/torrent.py @@ -886,13 +886,14 @@ class Torrent(object): def move_storage(self, dest): """Move a torrent's storage location""" - # Attempt to convert utf8 path to unicode - # Note: Inconsistent encoding for 'dest', needs future investigation - try: - dest_u = unicode(dest, "utf-8") - except TypeError: - # String is already unicode - dest_u = dest + if deluge.common.is_windows(): + # Attempt to convert utf8 path to unicode + # Note: Inconsistent encoding for 'dest', needs future investigation + try: + dest_u = unicode(dest, "utf-8") + except TypeError: + # String is already unicode + dest_u = dest if not os.path.exists(dest_u): try: