Reputation: 5722
CreateProcess suspended but it can't be resumed.
Here is my code:
bool success=CreateProcess(m_Process,
NULL,
NULL,
NULL,
FALSE,
NORMAL_PRIORITY_CLASS||CREATE_SUSPENDED,
NULL,
NULL,
&suInfo,
&procInfo);
if(!success){
MessageBoxA(0,"Could not create process...","ERROR",MB_OK);
return 1;
}
//we created it
//all good so go!
ResumeThread(procInfo.hThread);
Why this doesn't work?
Upvotes: 0
Views: 5718
Reputation: 5291
Remove one of the "|". This ends up as a one since it's a logical expression in your case. The constant for this is DEBUG_PROCESS, so you're debugging the child process.
Upvotes: 7