https://git.reactos.org/?p=reactos.git;a=commitdiff;h=ceccaae3112044aaf2a31…
commit ceccaae3112044aaf2a31925b3333faa1eb2cff9
Author: Serge Gautherie <32623169+SergeGautherie(a)users.noreply.github.com>
AuthorDate: Mon Jun 1 11:10:11 2020 +0200
Commit: GitHub <noreply(a)github.com>
CommitDate: Mon Jun 1 12:10:11 2020 +0300
[NTOS:MM] MmDeleteProcessAddressSpace(): Move 'Address' to where it belongs
(#2865)
No impact.
Detected by Cppcheck: unusedVariable.
Addendum to 2dade10d543589e1f5f762bbc1695f2917341171.
---
ntoskrnl/mm/marea.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/ntoskrnl/mm/marea.c b/ntoskrnl/mm/marea.c
index 37584477090..d953f422f96 100644
--- a/ntoskrnl/mm/marea.c
+++ b/ntoskrnl/mm/marea.c
@@ -572,7 +572,6 @@ MmDeleteProcessAddressSpace(PEPROCESS Process)
{
#ifndef _M_AMD64
KIRQL OldIrql;
- PVOID Address;
#endif
DPRINT("MmDeleteProcessAddressSpace(Process %p (%s))\n", Process,
@@ -591,7 +590,9 @@ MmDeleteProcessAddressSpace(PEPROCESS Process)
#if (_MI_PAGING_LEVELS == 2)
{
KIRQL OldIrql;
+ PVOID Address;
PMMPDE pointerPde;
+
/* Attach to Process */
KeAttachProcess(&Process->Pcb);