How to support LFS on ppc
JohnsonCheng
JohnsonCheng at qnap.com.tw
Wed Sep 14 19:12:09 EST 2005
Dear All,
I have a problem about Large File System on ppc. The following is my example
code:
#define _FILE_OFFSET_BITS 64
#include <sys/stat.h>
#include <unistd.h>
Int main()
{
struct stat buf;
stat64("/3G",&buf);
printf("size of test = %ld \n",buf.st_size);
lstat64("/3G",&buf);
printf("size of test 2= %ld\n",buf.st_size);
return 0;
}
The conclusion is as following:
size of test = 2141735952
size of test 2= 805910402
But the real size of 3G file is 3145728000. I think it maybe the offset is
wrong, but I don't know how to correct it. Can someone give me some advise.
Thanks,
Johnson Cheng
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ozlabs.org/pipermail/linuxppc-embedded/attachments/20050914/166cad55/attachment.htm
More information about the Linuxppc-embedded
mailing list