#include
#include
#include
#include
#include
int getFileSize(char* fileName)
{
int fd;
struct stat stat;
if(fd = open(fileName, O_RDONLY) < 0)
{
printf("Open file ERROR\n");
return(FALSE);
}
return((fstat(fd,&stat) < 0) ? FALSE : stat.st_size);
}
阅读(1776) | 评论(0) | 转发(0) |