#include <io.h> int nFileSize = _filelength(fp->_file); // dev // 或者 int nFileSize = _filelength(_fileno(fp)); // VS
nFileSize 单位:字节