https://git.reactos.org/?p=reactos.git;a=commitdiff;h=372eb0c0b8e09af0fa646c7e9245f49b65f05c2d

commit 372eb0c0b8e09af0fa646c7e9245f49b65f05c2d
Author:     Hermès Bélusca-Maïto <[email protected]>
AuthorDate: Mon Nov 28 00:43:22 2022 +0100
Commit:     Hermès Bélusca-Maïto <[email protected]>
CommitDate: Sun Mar 12 02:16:58 2023 +0100

    [NTOS:KDBG] Remove dead code. Addendum to baa47fa5e and fe777bb52.
---
 ntoskrnl/kdbg/kdb.c | 32 --------------------------------
 ntoskrnl/kdbg/kdb.h |  4 ----
 2 files changed, 36 deletions(-)

diff --git a/ntoskrnl/kdbg/kdb.c b/ntoskrnl/kdbg/kdb.c
index abe8f96b2cd..1b03f692ec5 100644
--- a/ntoskrnl/kdbg/kdb.c
+++ b/ntoskrnl/kdbg/kdb.c
@@ -1623,38 +1623,6 @@ continue_execution:
     return ContinueType;
 }
 
-KD_CONTINUE_TYPE
-KdbEnterDebuggerFirstChanceException(
-    IN OUT PKTRAP_FRAME TrapFrame)
-{
-    EXCEPTION_RECORD64 ExceptionRecord;
-    KD_CONTINUE_TYPE Return;
-    CONTEXT Context;
-
-    /* Copy TrapFrame to Context */
-    RtlZeroMemory(&Context, sizeof(CONTEXT));
-    Context.ContextFlags = CONTEXT_CONTROL | CONTEXT_INTEGER | 
CONTEXT_SEGMENTS | CONTEXT_FLOATING_POINT | CONTEXT_DEBUG_REGISTERS;
-#ifdef CONTEXT_EXTENDED_REGISTERS
-    Context.ContextFlags |= CONTEXT_EXTENDED_REGISTERS;
-#endif
-    KeTrapFrameToContext(TrapFrame, NULL, &Context);
-
-    /* Create ExceptionRecord (assume breakpoint) */
-    RtlZeroMemory(&ExceptionRecord, sizeof(EXCEPTION_RECORD64));
-    ExceptionRecord.ExceptionCode = STATUS_BREAKPOINT;
-
-    /* Call real function */
-    Return = KdbEnterDebuggerException(&ExceptionRecord,
-                                       KernelMode,
-                                       &Context,
-                                       TRUE);
-
-    /* Copy back Context to TrapFrame */
-    KeContextToTrapFrame(&Context, NULL, TrapFrame, Context.ContextFlags, 
KernelMode);
-
-    return Return;
-}
-
 VOID
 NTAPI
 KdbpGetCommandLineSettings(
diff --git a/ntoskrnl/kdbg/kdb.h b/ntoskrnl/kdbg/kdb.h
index 4424dd4837c..b606d4a5156 100644
--- a/ntoskrnl/kdbg/kdb.h
+++ b/ntoskrnl/kdbg/kdb.h
@@ -257,10 +257,6 @@ KdbEnterDebuggerException(IN PEXCEPTION_RECORD64 
ExceptionRecord,
                           IN OUT PCONTEXT Context,
                           IN BOOLEAN FirstChance);
 
-KD_CONTINUE_TYPE
-KdbEnterDebuggerFirstChanceException(
-    IN OUT PKTRAP_FRAME TrapFrame);
-
 /* other functions */
 
 NTSTATUS

Reply via email to