mirror of
https://github.com/neocturne/MinedMap.git
synced 2025-04-19 19:15:08 +02:00
use 'defined()' to keep nesting depth to one level
This commit is contained in:
parent
c70b0b7a13
commit
256964caf0
1 changed files with 5 additions and 7 deletions
|
@ -192,15 +192,13 @@ static int64_t getModTime(const std::string &file) {
|
|||
return INT64_MIN;
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
#if defined(_WIN32)
|
||||
return (int64_t)s.st_mtime * 1000000;
|
||||
#elif defined(__APPLE__)
|
||||
// stat.h syntax has changed on MacOSX SDK since at least 10.15
|
||||
return (int64_t)s.st_mtimespec.tv_sec * 1000000 + s.st_mtimespec.tv_nsec / 1000;
|
||||
#else
|
||||
#ifdef __APPLE__
|
||||
// stat.h syntax has changed on MacOSX SDK since at least 10.15
|
||||
return (int64_t)s.st_mtimespec.tv_sec * 1000000 + s.st_mtimespec.tv_nsec / 1000;
|
||||
#else
|
||||
return (int64_t)s.st_mtim.tv_sec * 1000000 + s.st_mtim.tv_nsec / 1000;
|
||||
#endif
|
||||
return (int64_t)s.st_mtim.tv_sec * 1000000 + s.st_mtim.tv_nsec / 1000;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue