Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Mac OS X equivalent for TerminateProcess(GetCurrentProcess,0);

I am looking for a simple and uncatchable way to terminate the Mac port of my C++ application. In Windows I was using

TerminateProcess(GetCurrentProcess, 0);

What's the equivalent command I can use with Mac OS X / XCode / GCC?

like image 288
Adrian Grigore Avatar asked Feb 15 '26 03:02

Adrian Grigore


1 Answers

Actually you want _exit if you want to have the same semantics as TerminateProcess. exit semantics are more closely aligned with ExitProcess.

like image 183
Matt Davison Avatar answered Feb 17 '26 16:02

Matt Davison



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!