Author: fireball
Date: Fri Jun 27 04:50:52 2008
New Revision: 34127
URL:
http://svn.reactos.org/svn/reactos?rev=34127&view=rev
Log:
- Add an initial breakpoint for usermode process startup, this makes usermode gdb
debugging working. Spotted and tested by Yury Sidorov.
Modified:
trunk/reactos/dll/ntdll/ldr/startup.c
Modified: trunk/reactos/dll/ntdll/ldr/startup.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/ntdll/ldr/startup.c?re…
==============================================================================
--- trunk/reactos/dll/ntdll/ldr/startup.c [iso-8859-1] (original)
+++ trunk/reactos/dll/ntdll/ldr/startup.c [iso-8859-1] Fri Jun 27 04:50:52 2008
@@ -484,6 +484,10 @@
ZwTerminateProcess(NtCurrentProcess(), STATUS_INVALID_IMAGE_FORMAT);
}
}
+
+ /* Break into debugger */
+ if (Peb->BeingDebugged) DbgBreakPoint();
+
/* attach the thread */
RtlEnterCriticalSection(NtCurrentPeb()->LoaderLock);
LdrpAttachThread();