Hello,
Let me give you another solution:
long filesize(FILE *stream)
{
long curpos, length;
curpos = ftell(stream);
fseek(stream, 0L, SEEK_END);
length = ftell(stream);
fseek(stream, curpos, SEEK_SET);
return length;
}
This is plain ANSI-C without Amiga-dependencies, so it should work on all machines...
To call it just open your file with fopen() and give the FilePointer to the function. After that you close the file again with fclose().
Hope that helps...