[求助]一个文件复制程序有问题
#define BUFFSIZE 512;
char buff[BUFFSIZE];
main(int argc,char * argv[])
{
int fd1,fd2,bytes;
if((fd1=open(argv[1],1))<0)
{
printf("cannot open file %s",argv[1]);
exit(0);
}
if((fd2=creat(argv[2],2))<0)
{
printf("cannot open file %s",argv[2]);
exit(0);
}
while((bytes=read(fd1,buff,BUFFSIZE))>0)
write(fd2,buff,bytes);
close(fd1);
close(fd2);
}
本人运行以后出现array bounds missing ],到底是怎么回事啊,谢谢指教
搜索更多相关的解决方案:
文件
----------------解决方案--------------------------------------------------------