kill a process started with popen

前端 未结 8 1361
温柔的废话
温柔的废话 2020-12-04 15:04

After opening a pipe to a process with popen, is there a way to kill the process that has been started? (Using pclose is not what I want because th

8条回答
  •  盖世英雄少女心
    2020-12-04 15:15

    The obvious way is system("pkill process_name");

    Clearly this is problematic if you have more than one instance of the process running.

提交回复
热议问题