mirror of
https://github.com/reactos/reactos.git
synced 2024-12-27 01:24:38 +00:00
- fixed uninitialized variable warning
- ProbeAndCaptureUnicodeString should check if allocating memory succeeded svn path=/trunk/; revision=18061
This commit is contained in:
parent
18494d1af0
commit
2148ae3457
2 changed files with 10 additions and 5 deletions
|
@ -130,11 +130,16 @@ ProbeAndCaptureUnicodeString(OUT PUNICODE_STRING Dest,
|
|||
/* Allocate space for the buffer */
|
||||
Buffer = ExAllocatePool(PagedPool, Dest->MaximumLength);
|
||||
|
||||
/* Copy it */
|
||||
RtlCopyMemory(Buffer, Dest->Buffer, Dest->MaximumLength);
|
||||
if (Buffer != NULL)
|
||||
{
|
||||
/* Copy it */
|
||||
RtlCopyMemory(Buffer, Dest->Buffer, Dest->MaximumLength);
|
||||
|
||||
/* Set it as the buffer */
|
||||
Dest->Buffer = Buffer;
|
||||
/* Set it as the buffer */
|
||||
Dest->Buffer = Buffer;
|
||||
}
|
||||
else
|
||||
Status = STATUS_INSUFFICIENT_RESOURCES;
|
||||
|
||||
/* Return */
|
||||
return Status;
|
||||
|
|
|
@ -1852,7 +1852,7 @@ NtLoadDriver(IN PUNICODE_STRING DriverServiceName)
|
|||
RTL_QUERY_REGISTRY_TABLE QueryTable[3];
|
||||
UNICODE_STRING ImagePath;
|
||||
UNICODE_STRING ServiceName;
|
||||
UNICODE_STRING CapturedDriverServiceName;
|
||||
UNICODE_STRING CapturedDriverServiceName = {0};
|
||||
KPROCESSOR_MODE PreviousMode;
|
||||
NTSTATUS Status;
|
||||
ULONG Type;
|
||||
|
|
Loading…
Reference in a new issue