Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如果我遇到feof()然后stat显示文件已经增长,有没有办法在不执行fclose()and的情况下读取添加的数据fopen()?
feof()
stat
fclose()
fopen()
是的。您可以调用clearerr文件,或执行任何查找操作,例如fseek(f, 0, SEEK_CUR).
clearerr
fseek(f, 0, SEEK_CUR)