mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
RegionSize in MEMORY_BASIC_INFORMATION is relative to BaseAddress, not to
AllocationBase svn path=/trunk/; revision=4608
This commit is contained in:
parent
458d8d250c
commit
ffebf21131
2 changed files with 6 additions and 3 deletions
|
@ -16,7 +16,7 @@
|
|||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*/
|
||||
/* $Id: anonmem.c,v 1.11 2003/04/26 23:13:32 hyperion Exp $
|
||||
/* $Id: anonmem.c,v 1.12 2003/04/28 10:37:39 gvg Exp $
|
||||
*
|
||||
* PROJECT: ReactOS kernel
|
||||
* FILE: ntoskrnl/mm/anonmem.c
|
||||
|
@ -877,10 +877,12 @@ MmQueryAnonMem(PMEMORY_AREA MemoryArea,
|
|||
Address, &RegionBase);
|
||||
Info->AllocationBase = RegionBase;
|
||||
Info->AllocationProtect = Region->Protect; /* FIXME */
|
||||
Info->RegionSize = Region->Length;
|
||||
Info->RegionSize = RegionBase + Region->Length - Info->BaseAddress;
|
||||
Info->State = Region->Type;
|
||||
Info->Protect = Region->Protect;
|
||||
Info->Type = MEM_PRIVATE;
|
||||
|
||||
*ResultLength = sizeof(MEMORY_BASIC_INFORMATION);
|
||||
return(STATUS_SUCCESS);
|
||||
}
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*/
|
||||
/* $Id: virtual.c,v 1.64 2002/09/08 10:23:37 chorns Exp $
|
||||
/* $Id: virtual.c,v 1.65 2003/04/28 10:37:40 gvg Exp $
|
||||
*
|
||||
* PROJECT: ReactOS kernel
|
||||
* FILE: ntoskrnl/mm/virtual.c
|
||||
|
@ -113,6 +113,7 @@ NtQueryVirtualMemory (IN HANDLE ProcessHandle,
|
|||
|
||||
if (Length != sizeof(MEMORY_BASIC_INFORMATION))
|
||||
{
|
||||
MmUnlockAddressSpace(AddressSpace);
|
||||
ObDereferenceObject(Process);
|
||||
return(STATUS_INFO_LENGTH_MISMATCH);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue