C中调用子程序

anthony570 2004-06-17 12:48:26
/*father.c*/
#include<stdio.h>
#include<process.h>
void main(){
execv("test.exe",NULL);
printf("father process");
getch();
}

/*test.c*/
#include<stdio.h>
void main(void){
printf("test process\n");
}
执行father.exe后,只显示了test process,没有father process。好像没有回到father,我该怎么办才能让它继续执行father余下的程序段?
...全文
35 回复 打赏 收藏 转发到动态 举报
写回复
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复

69,373

社区成员

发帖
与我相关
我的任务
社区描述
C语言相关问题讨论
社区管理员
  • C语言
  • 花神庙码农
  • 架构师李肯
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧