您的位置:首页 > Web前端

bug:error:too few arguments to function ‘fopen’

2014-09-04 13:47 246 查看

#define File_Path "cpu_usepercentage_file.txt";

void open_file(){

CPU_UsePercentage_File = fopen(File_Path,"ab");

if(CPU_UsePercentage_File == NULL){

printf("open CPU_UsePercentage_File error.\n");

exit(0);

}

}

报错:

CPUUsePercentage.c:40:33: error: expected ‘)’ before ‘;’ token

CPUUsePercentage.c:40:33: error: too few arguments to function ‘fopen’

原来是因为define后面错用了分号
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐