dnsi0 I post too much
Reputation: 0
Joined: 04 Jan 2007 Posts: 2674
|
Posted: Fri Jun 12, 2009 7:25 pm Post subject: [Help] Setting Flags... |
|
|
| Code: | TempHandle:=0;
TempHandle:=OpenThread(THREAD_GET_SET,False,te32.th32ThreadID);
SuspendThread(TempHandle);
GetThreadContext(TempHandle,SetContext);
SetContext.ContextFlags:=CONTEXT_CONTROL;
SetContext.EFlags:=SetContext.EFlags OR SetTrapFlag;
SetThreadContext(TempHandle,SetContext);
ResumeThread(TempHandle);
|
Here's the code I used to try and set the Trap Flag in the context of a thread that is not the thread that is executing the code. However, it crashes without errors or whatever.
|
|