level 2
kaiwanxiao41
楼主
FILE * fp;
int A[10];
char cpstr[20];
int i=0;
fp = fopen("D:\\nist-sts\\text.txt","r");
while(fgets(cpstr,10,fp))
{
A[i]=atoi(cpstr); i++;
}
CString str;
str.Format(L"%d",A[1]);
MessageBox(str);
fclose(fp);
return ;
运行后,出现这样的结果,哪里错了
7.29CopyFile.exe 中的 0x77597792 处最可能的异常: 0xC0000005: 写入位置 0x05f767c4 时发生访问冲突
2015年07月30日 01点07分
1
int A[10];
char cpstr[20];
int i=0;
fp = fopen("D:\\nist-sts\\text.txt","r");
while(fgets(cpstr,10,fp))
{
A[i]=atoi(cpstr); i++;
}
CString str;
str.Format(L"%d",A[1]);
MessageBox(str);
fclose(fp);
return ;
运行后,出现这样的结果,哪里错了
7.29CopyFile.exe 中的 0x77597792 处最可能的异常: 0xC0000005: 写入位置 0x05f767c4 时发生访问冲突