X-Git-Url: https://git.llucax.com/z.facultad/75.06/emufs.git/blobdiff_plain/381a5f98d66c8a3847d9918077a351b4813558fd..197ee2037c7b42f3750cac4cd8888a1c01556068:/emufs/common.c diff --git a/emufs/common.c b/emufs/common.c index f2dfc93..3906e05 100644 --- a/emufs/common.c +++ b/emufs/common.c @@ -46,6 +46,7 @@ long emufs_common_get_file_size(const char* filename, int* err) *err = EMUFS_ERROR_CANT_OPEN_FILE; return 0; } + fseek(file, 0, SEEK_END); file_size = ftell(file); fclose(file); if (file_size < 0) { @@ -55,4 +56,3 @@ long emufs_common_get_file_size(const char* filename, int* err) } return file_size; } -