mirror of
https://github.com/reactos/reactos.git
synced 2024-11-20 06:15:26 +00:00
[KMTESTS:IO] Correctly free name in IoFilesystem's TestAllInformation.
Spotted by Serge Gautherie.
This commit is contained in:
parent
9bc2a27393
commit
0cc3f19b80
1 changed files with 2 additions and 3 deletions
|
@ -73,7 +73,7 @@ TestAllInformation(VOID)
|
|||
PFILE_ALL_INFORMATION FileAllInfo;
|
||||
SIZE_T Length;
|
||||
ULONG NameLength;
|
||||
PWCHAR Name = NULL;
|
||||
PWCHAR Name;
|
||||
UNICODE_STRING NamePart;
|
||||
|
||||
InitializeObjectAttributes(&ObjectAttributes,
|
||||
|
@ -161,6 +161,7 @@ TestAllInformation(VOID)
|
|||
ok(RtlEqualUnicodeString(&NamePart, &Ntoskrnl, TRUE),
|
||||
"Name ends in '%wZ', expected %wZ\n", &NamePart, &Ntoskrnl);
|
||||
}
|
||||
ExFreePoolWithTag(Name, 'sFmK');
|
||||
}
|
||||
ok(FileAllInfo->NameInformation.FileName[NameLength / sizeof(WCHAR)] == 0xdddd,
|
||||
"Char past FileName is %x\n",
|
||||
|
@ -209,8 +210,6 @@ TestAllInformation(VOID)
|
|||
if (FileAllInfo)
|
||||
KmtFreeGuarded(FileAllInfo);
|
||||
|
||||
ExFreePoolWithTag(Name, 'sFmK');
|
||||
|
||||
Status = ObCloseHandle(FileHandle, KernelMode);
|
||||
ok_eq_hex(Status, STATUS_SUCCESS);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue