FileSystem: Partial revert of c82f800

Mixing stdio and raw FD access is a bad thing, filelength() isn't going to return correct results when extending a file has been buffered.
This commit is contained in:
Connor McLaughlin 2023-08-02 15:54:54 +10:00
parent 31029b2fe4
commit 68ad3e8db4
1 changed files with 0 additions and 8 deletions

View File

@ -748,13 +748,6 @@ s64 FileSystem::FTell64(std::FILE* fp)
s64 FileSystem::FSize64(std::FILE* fp)
{
#ifdef _WIN32
const int fd = _fileno(fp);
if (fd >= 0)
{
return _filelengthi64(fd);
}
#else
const s64 pos = FTell64(fp);
if (pos >= 0)
{
@ -765,7 +758,6 @@ s64 FileSystem::FSize64(std::FILE* fp)
return size;
}
}
#endif
return -1;
}