摘要: #include <sys/wait.h> int wait(int statloc); int waitpid(pid_t pid,int *statloc,int option); 两个函数返回值:若成功返回进程ID;若出错返回0或-1; 当一个进程正常或异常终止时,内核就向其父进程发送SIGC 阅读全文
posted @ 2022-08-07 20:59 撒西不纳拉 阅读(184) 评论(0) 推荐(0)
摘要: 参考这位大佬的文章:https://www.cnblogs.com/lr1402585172/p/10563642.html 阅读全文
posted @ 2022-08-07 19:36 撒西不纳拉 阅读(8) 评论(0) 推荐(0)
摘要: #include sigaction(int signo,const struct sigaction *act,struct sigaction *oact); 返回值:成功返回0;错误返回-1 struct sigaction{ void (*sa_handler)(int); /* 信号处理函 阅读全文
posted @ 2022-08-07 19:28 撒西不纳拉 阅读(112) 评论(0) 推荐(0)