Compare commits
No commits in common. "f61f3d5fa4b320ea609f16626884e5746a8e1e7f" and "a4d53c10119742a49219f6920417255463c53ff9" have entirely different histories.
f61f3d5fa4
...
a4d53c1011
@ -13,7 +13,6 @@
|
|||||||
* \#44 [bug] Windows-to-Linux remote mount ignores `CREATE_NEW`
|
* \#44 [bug] Windows-to-Linux remote mount ignores `CREATE_NEW`
|
||||||
* \#45 [bug] Windows-to-Linux remote mount is not handling attempts to remove a non-empty directory properly
|
* \#45 [bug] Windows-to-Linux remote mount is not handling attempts to remove a non-empty directory properly
|
||||||
* \#46 [bug] Changes to maximum cache size should be updated live
|
* \#46 [bug] Changes to maximum cache size should be updated live
|
||||||
* \#47 [bug] Windows-to-Linux remote mount is allowing directory rename when directory is not empty
|
|
||||||
|
|
||||||
### Changes from v2.0.5-rc
|
### Changes from v2.0.5-rc
|
||||||
|
|
||||||
|
@ -1448,22 +1448,15 @@ auto remote_server::winfsp_rename(PVOID /*file_desc*/, PWSTR file_name,
|
|||||||
ret = ((res < 0) ? static_cast<packet::error_type>(
|
ret = ((res < 0) ? static_cast<packet::error_type>(
|
||||||
utils::unix_error_to_windows(errno))
|
utils::unix_error_to_windows(errno))
|
||||||
: 0);
|
: 0);
|
||||||
} else {
|
} else if (utils::file::directory(file_path).exists()) {
|
||||||
auto dir{utils::file::directory(file_path)};
|
|
||||||
if (dir.exists()) {
|
|
||||||
if (dir.count(false) == 0U) {
|
|
||||||
res = drive_.rename_directory(construct_api_path(file_path),
|
res = drive_.rename_directory(construct_api_path(file_path),
|
||||||
construct_api_path(new_file_path));
|
construct_api_path(new_file_path));
|
||||||
ret = ((res < 0)
|
ret =
|
||||||
? errno == EISDIR
|
((res < 0) ? errno == EISDIR
|
||||||
? static_cast<packet::error_type>(STATUS_ACCESS_DENIED)
|
? static_cast<packet::error_type>(STATUS_ACCESS_DENIED)
|
||||||
: static_cast<packet::error_type>(
|
: static_cast<packet::error_type>(
|
||||||
utils::unix_error_to_windows(errno))
|
utils::unix_error_to_windows(errno))
|
||||||
: 0);
|
: 0);
|
||||||
} else {
|
|
||||||
ret = static_cast<packet::error_type>(STATUS_DIRECTORY_NOT_EMPTY);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
RAISE_REMOTE_FUSE_SERVER_EVENT(function_name, file_path + "|" + new_file_path,
|
RAISE_REMOTE_FUSE_SERVER_EVENT(function_name, file_path + "|" + new_file_path,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user