1
0
Fork 0

Remove 2 occurrences of 'varset("$hp", fdProcessInfo->hProcess)', one of which was being called with the initial handle from CreateProcess(). cbCreateProcess is now the only place where this variable is set, for both types of debug sessions (attaching or creating)

This commit is contained in:
Mattiwatti 2017-11-27 20:00:28 +01:00 committed by Duncan Ogilvie
parent 629a6022e4
commit 2f3f28746d
1 changed files with 0 additions and 2 deletions

View File

@ -1990,7 +1990,6 @@ static void cbAttachDebugger()
cmddirectexec(StringUtils::sprintf("resumethread %p", tidToResume).c_str());
tidToResume = 0;
}
varset("$hp", (duint)fdProcessInfo->hProcess, true);
varset("$pid", fdProcessInfo->dwProcessId, true);
}
@ -2662,7 +2661,6 @@ static void debugLoopFunction(void* lpParameter, bool attach)
}
//set script variables
varset("$hp", (duint)fdProcessInfo->hProcess, true);
varset("$pid", fdProcessInfo->dwProcessId, true);
if(!OpenProcessToken(fdProcessInfo->hProcess, TOKEN_ALL_ACCESS, &hProcessToken))