Module: deluge Branch: 1.3-stable Commit: 25e58bc8a2ae27857d822489c6a2b2c75cc7f208
Author: Andrew Resch <[email protected]> Date: Thu Jan 27 11:11:28 2011 -0800 Fix #1498: Use os.path.normpath on new_folder to remove any double slashes or other problems that could be in the string --- deluge/core/torrent.py | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/deluge/core/torrent.py b/deluge/core/torrent.py index 50a05b2..ac81e15 100644 --- a/deluge/core/torrent.py +++ b/deluge/core/torrent.py @@ -889,8 +889,8 @@ class Torrent(object): log.error("Attempting to rename a folder with an invalid folder name: %s", new_folder) return - if new_folder[-1:] != "/": - new_folder += "/" + # Make sure the new folder path is nice and has a trailing slash + new_folder = os.path.norm(new_folder) + "/" wait_on_folder = (folder, new_folder, []) for f in self.get_files(): -- 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.
