rename_file now creates missing directories before renaming
This commit is contained in:
parent
ef42e8f77c
commit
ba28449765
|
@ -587,6 +587,7 @@ namespace libtorrent
|
|||
// if old path doesn't exist, just rename the file
|
||||
// in our file_storage, so that when it is created
|
||||
// it will get the new name
|
||||
create_directories(new_path.branch_path());
|
||||
if (exists(old_path)) rename(old_path, new_path);
|
||||
/*
|
||||
error_code ec;
|
||||
|
|
Loading…
Reference in New Issue