What is the correct way to force an app to core dump and quit?

前端 未结 5 1723
醉梦人生
醉梦人生 2021-01-12 19:19

I just came across some code which used the kill system call to send a SIGSEGV signal to an app. The rationale behind this was that this would force the app to core dump and

5条回答
  •  孤城傲影
    2021-01-12 19:56

    Yes. kill is somewhat misnamed -- it can send any signal. There are many uses for kill which don't result in the process being killed at all!

提交回复
热议问题