mirror of
https://git.code.sf.net/p/ntfs-3g/ntfs-3g.git
synced 2025-01-22 16:23:37 +08:00
fix stupid bug in ntfs_delete, optimize it a bit
This commit is contained in:
parent
8afb8a0daa
commit
5ca19a130b
@ -1282,11 +1282,18 @@ search:
|
||||
errno = 0;
|
||||
fn = (FILE_NAME_ATTR*)((u8*)actx->attr +
|
||||
le16_to_cpu(actx->attr->value_offset));
|
||||
if (looking_for_dos_name && fn->file_name_type == FILE_NAME_DOS)
|
||||
break;
|
||||
if (looking_for_win32_name &&
|
||||
fn->file_name_type == FILE_NAME_WIN32)
|
||||
break;
|
||||
if (looking_for_dos_name) {
|
||||
if (fn->file_name_type == FILE_NAME_DOS)
|
||||
break;
|
||||
else
|
||||
continue;
|
||||
}
|
||||
if (looking_for_win32_name) {
|
||||
if (fn->file_name_type == FILE_NAME_WIN32)
|
||||
break;
|
||||
else
|
||||
continue;
|
||||
}
|
||||
if (dir_ni->mft_no == MREF_LE(fn->parent_directory) &&
|
||||
ntfs_names_are_equal(fn->file_name,
|
||||
fn->file_name_length, name,
|
||||
@ -1295,7 +1302,6 @@ search:
|
||||
ni->vol->upcase, ni->vol->upcase_len)) {
|
||||
if (fn->file_name_type == FILE_NAME_WIN32) {
|
||||
looking_for_dos_name = TRUE;
|
||||
ntfs_attr_reinit_search_ctx(actx);
|
||||
continue;
|
||||
}
|
||||
if (fn->file_name_type == FILE_NAME_DOS)
|
||||
|
Loading…
Reference in New Issue
Block a user