diff options
author | Andrew Resch <andrewresch@gmail.com> | 2010-07-12 14:45:13 -0700 |
---|---|---|
committer | Andrew Resch <andrewresch@gmail.com> | 2010-07-12 14:45:51 -0700 |
commit | 72ec926c1afdb312ad51dfbbac117c1775abfdb6 (patch) | |
tree | 6db33fd2ec1e5738252239157c344905be5eb74e | |
parent | 0d431ae7dbdce5d6c90061ce1ba20ec35358c9af (diff) | |
download | deluge-72ec926c1afdb312ad51dfbbac117c1775abfdb6.tar.gz deluge-72ec926c1afdb312ad51dfbbac117c1775abfdb6.tar.bz2 deluge-72ec926c1afdb312ad51dfbbac117c1775abfdb6.zip |
Do not attempt to move a torrents storage if the destination path does
not exist
-rw-r--r-- | deluge/core/torrent.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/deluge/core/torrent.py b/deluge/core/torrent.py index f9f80ca7a..dc569c5f8 100644 --- a/deluge/core/torrent.py +++ b/deluge/core/torrent.py @@ -794,6 +794,9 @@ class Torrent(object): def move_storage(self, dest): """Move a torrent's storage location""" + if not os.path.exists(dest): + log.error("Could not move storage for torrent %s since %s does not exist!", self.torrent_id, dest) + return False try: self.handle.move_storage(dest.encode("utf8")) except: |