69,382
社区成员
发帖
与我相关
我的任务
分享
void
6 pr_exit(ing status)
7 {
8 if(WIFEXITED(status))
9 printf("normal termination, exit status = %d\n", WEXITSTATUS(status));
10 else if(WIFSIGNALED(status))
11 printf("abnormal termination, signal number = %d%s", WTERMSIG(status),
12 #ifdef WCOREDUMP
13 WCOREDUMP(status) ? "(core file generated)" : "");
14 #else
15 "");
16 #endif
17 else if(WIFSTOPPED(status))
18 printf("child stopped, singal number = %d\n", WSTOPSIG(status));
19 }
#ifdef WCOREDUMP
WCOREDUMP(status) ? "(core file generated)" : ")");
#else
")");
void
pr_exit(ing status)
{
if(WIFEXITED(status))
printf("normal termination, exit status = %d\n", WEXITSTATUS(status));
else if(WIFSIGNALED(status))
printf("abnormal termination, signal number = %d%s", WTERMSIG(status),
#ifdef WCOREDUMP
WCOREDUMP(status) ? "(core file generated)" : "");
#else
"");
#endif
else if(WIFSTOPPED(status))
printf("child stopped, singal number = %d\n", WSTOPSIG(status));
}