[*] Clean up
This commit is contained in:
parent
e1e1da8e1b
commit
6afe6c7342
@ -198,25 +198,25 @@ namespace Aurora::Time
|
||||
|
||||
AUKN_SYM tm ToCivilTime(AuInt64 time, bool UTC)
|
||||
{
|
||||
std::tm ret{};
|
||||
std::tm ret {};
|
||||
auto timet = MSToCTime(time);
|
||||
if (UTC)
|
||||
{
|
||||
#if defined(AURORA_COMPILER_MSVC)
|
||||
#if defined(AURORA_COMPILER_MSVC)
|
||||
auto tm = gmtime_s(&ret, &timet);
|
||||
#else
|
||||
#else
|
||||
auto tm = gmtime_r(&timet, &ret);
|
||||
#endif
|
||||
#if defined(AURORA_COMPILER_MSVC)
|
||||
#endif
|
||||
#if defined(AURORA_COMPILER_MSVC)
|
||||
SysAssert(!tm, "couldn't convert civil time");
|
||||
#else
|
||||
#else
|
||||
SysAssert(tm, "couldn't convert civil time");
|
||||
#endif
|
||||
#endif
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
#if defined(AURORA_COMPILER_MSVC)
|
||||
#if defined(AURORA_COMPILER_MSVC)
|
||||
if (localtime_s(&ret, &timet))
|
||||
#else
|
||||
if (!localtime_r(&timet, &ret))
|
||||
|
Loading…
Reference in New Issue
Block a user