mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
RtlFreeUnicodeString -> ExFreePool changes
svn path=/trunk/; revision=15021
This commit is contained in:
parent
6758bb095b
commit
cb0daf73fd
6 changed files with 27 additions and 27 deletions
|
@ -125,14 +125,14 @@ InitSystemSharedUserPage (PCSZ ParameterLine)
|
|||
&ObjectAttributes);
|
||||
|
||||
/* Free the String */
|
||||
RtlFreeUnicodeString(&ArcName);
|
||||
ExFreePool(ArcName.Buffer);
|
||||
|
||||
/* Check for Success */
|
||||
if (!NT_SUCCESS(Status)) {
|
||||
|
||||
/* Free the Strings */
|
||||
RtlFreeUnicodeString(&BootPath);
|
||||
RtlFreeUnicodeString(&ArcDeviceName);
|
||||
ExFreePool(ArcDeviceName.Buffer);
|
||||
CPRINT("NtOpenSymbolicLinkObject() failed (Status %x)\n", Status);
|
||||
KEBUGCHECK(0);
|
||||
}
|
||||
|
@ -148,7 +148,7 @@ InitSystemSharedUserPage (PCSZ ParameterLine)
|
|||
|
||||
/* Free the Strings */
|
||||
RtlFreeUnicodeString(&BootPath);
|
||||
RtlFreeUnicodeString(&ArcDeviceName);
|
||||
ExFreePool(ArcDeviceName.Buffer);
|
||||
CPRINT("NtQuerySymbolicLinkObject() failed (Status %x)\n", Status);
|
||||
KEBUGCHECK(0);
|
||||
}
|
||||
|
@ -209,8 +209,8 @@ InitSystemSharedUserPage (PCSZ ParameterLine)
|
|||
|
||||
/* Free all the Strings we have in memory */
|
||||
RtlFreeUnicodeString (&BootPath);
|
||||
RtlFreeUnicodeString (&DriveDeviceName);
|
||||
RtlFreeUnicodeString (&ArcDeviceName);
|
||||
ExFreePool(DriveDeviceName.Buffer);
|
||||
ExFreePool(ArcDeviceName.Buffer);
|
||||
|
||||
/* Make sure we found the Boot Drive */
|
||||
if (BootDriveFound == FALSE) {
|
||||
|
|
|
@ -413,15 +413,15 @@ IoCreateSystemRootLink(PCHAR ParameterLine)
|
|||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
RtlFreeUnicodeString(&BootPath);
|
||||
RtlFreeUnicodeString(&DeviceName);
|
||||
ExFreePool(DeviceName.Buffer);
|
||||
CPRINT("ZwOpenSymbolicLinkObject() '%wZ' failed (Status %x)\n",
|
||||
&ArcName,
|
||||
Status);
|
||||
RtlFreeUnicodeString(&ArcName);
|
||||
ExFreePool(ArcName.Buffer);
|
||||
|
||||
return(Status);
|
||||
}
|
||||
RtlFreeUnicodeString(&ArcName);
|
||||
ExFreePool(ArcName.Buffer);
|
||||
|
||||
Status = ZwQuerySymbolicLinkObject(Handle,
|
||||
&DeviceName,
|
||||
|
@ -430,7 +430,7 @@ IoCreateSystemRootLink(PCHAR ParameterLine)
|
|||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
RtlFreeUnicodeString(&BootPath);
|
||||
RtlFreeUnicodeString(&DeviceName);
|
||||
ExFreePool(DeviceName.Buffer);
|
||||
CPRINT("ZwQuerySymbolicObject() failed (Status %x)\n",
|
||||
Status);
|
||||
|
||||
|
@ -450,7 +450,7 @@ IoCreateSystemRootLink(PCHAR ParameterLine)
|
|||
|
||||
Status = IoCreateSymbolicLink(&LinkName,
|
||||
&DeviceName);
|
||||
RtlFreeUnicodeString (&DeviceName);
|
||||
ExFreePool(DeviceName.Buffer);
|
||||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
CPRINT("IoCreateSymbolicLink() failed (Status %x)\n",
|
||||
|
|
|
@ -188,7 +188,7 @@ IopDeleteDriver(PVOID ObjectBody)
|
|||
DPRINT("IopDeleteDriver(ObjectBody %x)\n", ObjectBody);
|
||||
|
||||
ExFreePool(Object->DriverExtension);
|
||||
RtlFreeUnicodeString(&Object->DriverName);
|
||||
ExFreePool(Object->DriverName.Buffer);
|
||||
|
||||
OldIrql = KeRaiseIrqlToDpcLevel();
|
||||
|
||||
|
@ -197,7 +197,7 @@ IopDeleteDriver(PVOID ObjectBody)
|
|||
DriverExtension = NextDriverExtension)
|
||||
{
|
||||
NextDriverExtension = DriverExtension->Link;
|
||||
ExFreePool(DriverExtension);
|
||||
ExFreePoolWithTag(DriverExtension, TAG_DRIVER_EXTENSION);
|
||||
}
|
||||
|
||||
KfLowerIrql(OldIrql);
|
||||
|
@ -358,7 +358,7 @@ IopNormalizeImagePath(
|
|||
|
||||
wcscpy(ImagePath->Buffer, L"\\SystemRoot\\");
|
||||
wcscat(ImagePath->Buffer, InputImagePath.Buffer);
|
||||
RtlFreeUnicodeString(&InputImagePath);
|
||||
ExFreePool(InputImagePath.Buffer);
|
||||
}
|
||||
|
||||
return STATUS_SUCCESS;
|
||||
|
@ -496,7 +496,7 @@ IopLoadServiceModule(
|
|||
Status = STATUS_IMAGE_ALREADY_LOADED;
|
||||
}
|
||||
|
||||
RtlFreeUnicodeString(&ServiceImagePath);
|
||||
ExFreePool(ServiceImagePath.Buffer);
|
||||
|
||||
/*
|
||||
* Now check if the module was loaded successfully.
|
||||
|
@ -908,8 +908,8 @@ IopCreateServiceListEntry(PUNICODE_STRING ServiceName)
|
|||
NULL);
|
||||
if (!NT_SUCCESS(Status) || Service->Start > 1)
|
||||
{
|
||||
RtlFreeUnicodeString(&Service->ServiceGroup);
|
||||
RtlFreeUnicodeString(&Service->ImagePath);
|
||||
ExFreePool(Service->ServiceGroup.Buffer);
|
||||
ExFreePool(Service->ImagePath.Buffer);
|
||||
ExFreePool(Service);
|
||||
return(Status);
|
||||
}
|
||||
|
@ -1065,7 +1065,7 @@ IoDestroyDriverList(VOID)
|
|||
{
|
||||
CurrentGroup = CONTAINING_RECORD(GroupEntry, SERVICE_GROUP, GroupListEntry);
|
||||
|
||||
RtlFreeUnicodeString(&CurrentGroup->GroupName);
|
||||
ExFreePool(CurrentGroup->GroupName.Buffer);
|
||||
RemoveEntryList(GroupEntry);
|
||||
if (CurrentGroup->TagArray)
|
||||
{
|
||||
|
@ -1082,10 +1082,10 @@ IoDestroyDriverList(VOID)
|
|||
{
|
||||
CurrentService = CONTAINING_RECORD(ServiceEntry, SERVICE, ServiceListEntry);
|
||||
|
||||
RtlFreeUnicodeString(&CurrentService->ServiceName);
|
||||
RtlFreeUnicodeString(&CurrentService->RegistryPath);
|
||||
RtlFreeUnicodeString(&CurrentService->ServiceGroup);
|
||||
RtlFreeUnicodeString(&CurrentService->ImagePath);
|
||||
ExFreePool(CurrentService->ServiceName.Buffer);
|
||||
ExFreePool(CurrentService->RegistryPath.Buffer);
|
||||
ExFreePool(CurrentService->ServiceGroup.Buffer);
|
||||
ExFreePool(CurrentService->ImagePath.Buffer);
|
||||
RemoveEntryList(ServiceEntry);
|
||||
ExFreePool(CurrentService);
|
||||
|
||||
|
@ -1547,7 +1547,7 @@ IopUnloadDriver(PUNICODE_STRING DriverServiceName, BOOLEAN UnloadPnpDrivers)
|
|||
* Free the service path
|
||||
*/
|
||||
|
||||
RtlFreeUnicodeString(&ImagePath);
|
||||
ExFreePool(ImagePath.Buffer);
|
||||
|
||||
/*
|
||||
* Unload the module and release the references to the device object
|
||||
|
@ -1865,7 +1865,7 @@ NtLoadDriver(IN PUNICODE_STRING DriverServiceName)
|
|||
if (!NT_SUCCESS(Status))
|
||||
{
|
||||
DPRINT("RtlQueryRegistryValues() failed (Status %lx)\n", Status);
|
||||
RtlFreeUnicodeString(&ImagePath);
|
||||
ExFreePool(ImagePath.Buffer);
|
||||
goto ReleaseCapturedString;
|
||||
}
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
/* GLOBALS *******************************************************************/
|
||||
|
||||
#define TAG_IRP TAG('I', 'R', 'P', ' ')
|
||||
#define TAG_SYS_BUF TAG('I', 'o', ' ' , ' ')
|
||||
#define TAG_SYS_BUF TAG('S', 'Y', 'S' , 'B')
|
||||
|
||||
/* FUNCTIONS *****************************************************************/
|
||||
|
||||
|
|
|
@ -72,7 +72,7 @@ ObpDeleteSymbolicLink(PVOID ObjectBody)
|
|||
{
|
||||
PSYMLINK_OBJECT SymlinkObject = (PSYMLINK_OBJECT)ObjectBody;
|
||||
|
||||
RtlFreeUnicodeString(&SymlinkObject->TargetName);
|
||||
ExFreePool(SymlinkObject->TargetName.Buffer);
|
||||
}
|
||||
|
||||
|
||||
|
@ -129,7 +129,7 @@ ObpParseSymbolicLink(PVOID Object,
|
|||
}
|
||||
|
||||
/* transfer target path buffer into FullPath */
|
||||
RtlFreeUnicodeString(FullPath);
|
||||
ExFreePool(FullPath->Buffer);
|
||||
FullPath->Length = TargetPath.Length;
|
||||
FullPath->MaximumLength = TargetPath.MaximumLength;
|
||||
FullPath->Buffer = TargetPath.Buffer;
|
||||
|
|
|
@ -123,7 +123,7 @@ RtlReleaseCapturedUnicodeString(IN PUNICODE_STRING CapturedString,
|
|||
{
|
||||
if(CurrentMode != KernelMode || CaptureIfKernel )
|
||||
{
|
||||
RtlFreeUnicodeString(CapturedString);
|
||||
ExFreePool(CapturedString->Buffer);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue