SYSTEM(3)
system - execute a shell command
#include <stdlib.h>
int system(const char *string);
执行shell命令。通过调用/bin/sh -c string,执行命令然后返回。在执行命令中,SIGCHLD阻塞,SIGINT SIGQUIT被忽略。
返回命令的状态,或者-1表示出错。
system - execute a shell command
#include <stdlib.h>
int system(const char *string);
执行shell命令。通过调用/bin/sh -c string,执行命令然后返回。在执行命令中,SIGCHLD阻塞,SIGINT SIGQUIT被忽略。
返回命令的状态,或者-1表示出错。