23 lines
756 B
Diff
23 lines
756 B
Diff
|
--- a/deps/spdlog/include/spdlog/details/os-inl.h
|
||
|
+++ b/deps/spdlog/include/spdlog/details/os-inl.h
|
||
|
@@ -236,20 +236,11 @@
|
||
|
# else
|
||
|
int fd = ::fileno(f);
|
||
|
# endif
|
||
|
-// 64 bits(but not in osx or cygwin, where fstat64 is deprecated)
|
||
|
-# if (defined(__linux__) || defined(__sun) || defined(_AIX)) && (defined(__LP64__) || defined(_LP64))
|
||
|
- struct stat64 st;
|
||
|
- if (::fstat64(fd, &st) == 0)
|
||
|
- {
|
||
|
- return static_cast<size_t>(st.st_size);
|
||
|
- }
|
||
|
-# else // other unix or linux 32 bits or cygwin
|
||
|
struct stat st;
|
||
|
if (::fstat(fd, &st) == 0)
|
||
|
{
|
||
|
return static_cast<size_t>(st.st_size);
|
||
|
}
|
||
|
-# endif
|
||
|
#endif
|
||
|
throw_spdlog_ex("Failed getting file size from fd", errno);
|
||
|
return 0; // will not be reached.
|