linux下c语言怎么调用shell脚本

2025-04-05 12:18:59
推荐回答(1个)
回答1:

两种方法
比如调用ifconfig命令
可以
system("ifconfig");
也可以
FILE *fp = popen("ifconfig", "rb");