wbe
November 29th, 2001, 17:28
What's the difference between the two? Is there any other API used to terminate (exit) a program?
Thanks
Thanks
View Full Version : ExitProcess and TerminateProcess
This function terminates the specified process and all of its threads. [...] Remarks The TerminateProcess function is used to unconditionally cause a process to exit. Use it only in extreme circumstances. The state of global data maintained by dynamic-link libraries (DLLs) may be compromised if TerminateProcess. TerminateProcess causes all threads within a process to terminate, and causes a process to exit, but DLLs attached to the process are not notified that the process is terminating. Terminating a process causes the following: All of the object handles opened by the process are closed.Terminating a process does not cause child processes to be terminated. Terminating a process does not necessarily remove the process object from the system. A process object is deleted when the last handle to the process is closed. |