mirror of
https://github.com/reactos/reactos.git
synced 2025-02-22 08:25:03 +00:00
[NTOSKRNL]
Fix potential buffer overflow svn path=/trunk/; revision=49659
This commit is contained in:
parent
bb5c7012d3
commit
ebec2dd826
1 changed files with 3 additions and 7 deletions
|
@ -1206,14 +1206,10 @@ KiRosFrldrLpbToNtLpb(IN PROS_LOADER_PARAMETER_BLOCK RosLoaderBlock,
|
|||
0,
|
||||
&Base);
|
||||
|
||||
//
|
||||
// Check if we have a ramdisk
|
||||
//
|
||||
/* Check if we have a ramdisk */
|
||||
if ((RosLoaderBlock->RdAddr) && (RosLoaderBlock->RdLength))
|
||||
{
|
||||
//
|
||||
// Build a descriptor for it
|
||||
//
|
||||
/* Build a descriptor for it */
|
||||
KiRosAllocateNtDescriptor(LoaderXIPRom,
|
||||
KERNEL_DESCRIPTOR_PAGE(RosLoaderBlock->RdAddr),
|
||||
(RosLoaderBlock->RdLength + PAGE_SIZE - 1) >> PAGE_SHIFT,
|
||||
|
@ -1267,7 +1263,7 @@ KiRosFrldrLpbToNtLpb(IN PROS_LOADER_PARAMETER_BLOCK RosLoaderBlock,
|
|||
HalPath = strchr(BootPath + 1, ' ');
|
||||
*HalPath = ANSI_NULL;
|
||||
BldrNtBootPath[0] = '\\';
|
||||
strncat(BldrNtBootPath, BootPath + 1, 63);
|
||||
strncat(BldrNtBootPath, BootPath + 1, 61);
|
||||
strcat(BldrNtBootPath,"\\");
|
||||
LoaderBlock->NtBootPathName = BldrNtBootPath;
|
||||
|
||||
|
|
Loading…
Reference in a new issue