mirror of
https://github.com/RPCSX/rpcsx.git
synced 2024-12-04 09:23:27 +00:00
[orbis-kernel] Fix sys_localtime_to_utc
This commit is contained in:
parent
0d7f50a246
commit
1d4b96b3de
@ -872,7 +872,8 @@ orbis::SysResult orbis::sys_localtime_to_utc(Thread *thread, int64_t time,
|
||||
int *_dst_sec) {
|
||||
ORBIS_LOG_TRACE(__FUNCTION__, time, unk, ptime, _sec, _dst_sec);
|
||||
struct ::tm tp;
|
||||
auto result = ::mktime(::gmtime_r(&time, &tp));
|
||||
::time_t timez = 0;
|
||||
auto result = time - ::mktime(::localtime_r(&timez, &tp));
|
||||
if (auto e = uwrite(ptime, result); e != ErrorCode{})
|
||||
return e;
|
||||
uwrite(_sec, {});
|
||||
|
Loading…
Reference in New Issue
Block a user