mirror of
https://github.com/reactos/reactos.git
synced 2025-05-16 15:50:24 +00:00
[NTFS]
Support full data stream name on open (i.e., stream name finished with :$DATA) svn path=/trunk/; revision=68811
This commit is contained in:
parent
5f9af4a19f
commit
8b651ad6d9
1 changed files with 18 additions and 1 deletions
|
@ -545,7 +545,7 @@ NtfsDirFindFile(PNTFS_VCB Vcb,
|
|||
UNICODE_STRING File;
|
||||
PFILE_RECORD_HEADER FileRecord;
|
||||
ULONGLONG MFTIndex;
|
||||
PWSTR Colon;
|
||||
PWSTR Colon, OldColon;
|
||||
PNTFS_ATTR_CONTEXT DataContext;
|
||||
USHORT Length = 0;
|
||||
|
||||
|
@ -561,6 +561,23 @@ NtfsDirFindFile(PNTFS_VCB Vcb,
|
|||
Length = File.Length;
|
||||
File.Length = (Colon - FileToFind) * sizeof(WCHAR);
|
||||
|
||||
if (_wcsicmp(Colon + 1, L"$DATA") == 0)
|
||||
{
|
||||
OldColon = Colon;
|
||||
Colon[0] = UNICODE_NULL;
|
||||
Colon = wcsrchr(FileToFind, L':');
|
||||
if (Colon != NULL)
|
||||
{
|
||||
Length = File.Length;
|
||||
File.Length = (Colon - FileToFind) * sizeof(WCHAR);
|
||||
}
|
||||
else
|
||||
{
|
||||
Colon = OldColon;
|
||||
Colon[0] = L':';
|
||||
}
|
||||
}
|
||||
|
||||
/* Skip colon */
|
||||
++Colon;
|
||||
DPRINT1("Will now look for file '%wZ' with stream '%S'\n", &File, Colon);
|
||||
|
|
Loading…
Reference in a new issue