mirror of
https://git.deluge-torrent.org/deluge
synced 2025-04-20 03:24:54 +00:00
Fix renaming folders on libtorrent 0.16 compiled with unicode support (Windows)
This commit is contained in:
parent
92eb9feae4
commit
c58221c866
1 changed files with 5 additions and 1 deletions
|
@ -960,7 +960,11 @@ class Torrent(object):
|
|||
if f["path"].startswith(folder):
|
||||
# Keep a list of filerenames we're waiting on
|
||||
wait_on_folder[2].append(f["index"])
|
||||
self.handle.rename_file(f["index"], f["path"].replace(folder, new_folder, 1).encode("utf-8"))
|
||||
new_path = f["path"].replace(folder, new_folder, 1)
|
||||
try:
|
||||
self.handle.rename_file(f["index"], new_path)
|
||||
except TypeError:
|
||||
self.handle.rename_file(f["index"], new_path.encode("utf-8"))
|
||||
self.waiting_on_folder_rename.append(wait_on_folder)
|
||||
|
||||
def cleanup_prev_status(self):
|
||||
|
|
Loading…
Add table
Reference in a new issue