hello,


call StartServiceCtrlDispatcherA
dec eax
jne  somewhere

push 0
call ExitThread


does the code above do exactly the same thing as the one below?
one calls ExitThread after the StartServiceCtrlDispatcherA api, and the other one calls ExitProcess.


call StartServiceCtrlDispatcherA
dec eax
jne  somewhere

push 0
call ExitProcess
Posted on 2012-07-08 17:22:26 by hakand
Not the same.
ExitProcess will cause all threads to terminate...
ExitThread will only terminate the thread who calls it - this might be bad depending on what you have constructed.
Posted on 2012-07-09 01:26:27 by Homer