Skip to content

Commit

Permalink
Fix build error on Windows with Clang
Browse files Browse the repository at this point in the history
Resolves google#1018
  • Loading branch information
SpinnerX committed Jun 4, 2024
1 parent 6bbd3be commit 17a1567
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/draco/io/stdio_file_reader.cc
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,12 @@ size_t StdioFileReader::GetFileSize() {
return false;
}

#if _FILE_OFFSET_BITS == 64
const size_t file_size = static_cast<size_t>(ftello(file_));
#if _WIN32
const size_t file_size = static_cast<size_t>(ftell(file_));
#elif defined _WIN64
const size_t file_size = static_cast<size_t>(_ftelli64(file_));
#else
const size_t file_size = static_cast<size_t>(ftell(file_));
#elif _FILE_OFFSET_BITS == 64
const size_t file_size = static_cast<size_t>(ftello(file_));
#endif

rewind(file_);
Expand Down

0 comments on commit 17a1567

Please sign in to comment.