发布网友
共3个回答
热心网友
int iRetCode;
char sStr[100];
sprintf(sStr,"home/test/upload/unload.sh");
iRetCode=system(sStr);
if(iRetCode<0)
{
printf("shell error!");
}
热心网友
好像是execute
然后里面直接可以用bash指令
热心网友
system(“这里是你要执行的脚本文件的绝对位置或者相对位置”);