summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2020-01-20 21:36:30 +0100
committerGitHub <noreply@github.com>2020-01-20 21:36:30 +0100
commitbc55c05947030ba746d9d8e7e90660efe151ded7 (patch)
treece8b9f4f0f8cad35a352c27c81e04c059dc274ee /src
parentMerge pull request #3332 from bunnei/config-audio-tab (diff)
parenttime: Fix month off-by-one error. (diff)
downloadyuzu-bc55c05947030ba746d9d8e7e90660efe151ded7.tar
yuzu-bc55c05947030ba746d9d8e7e90660efe151ded7.tar.gz
yuzu-bc55c05947030ba746d9d8e7e90660efe151ded7.tar.bz2
yuzu-bc55c05947030ba746d9d8e7e90660efe151ded7.tar.lz
yuzu-bc55c05947030ba746d9d8e7e90660efe151ded7.tar.xz
yuzu-bc55c05947030ba746d9d8e7e90660efe151ded7.tar.zst
yuzu-bc55c05947030ba746d9d8e7e90660efe151ded7.zip
Diffstat (limited to '')
-rw-r--r--src/core/hle/service/time/time_zone_manager.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/hle/service/time/time_zone_manager.cpp b/src/core/hle/service/time/time_zone_manager.cpp
index 4db6d7ad3..717e81818 100644
--- a/src/core/hle/service/time/time_zone_manager.cpp
+++ b/src/core/hle/service/time/time_zone_manager.cpp
@@ -820,7 +820,7 @@ static ResultCode ToCalendarTimeImpl(const TimeZoneRule& rules, s64 time, Calend
const ResultCode result{
ToCalendarTimeInternal(rules, time, calendar_time, calendar.additiona_info)};
calendar.time.year = static_cast<s16>(calendar_time.year);
- calendar.time.month = calendar_time.month;
+ calendar.time.month = calendar_time.month + 1; // Internal impl. uses 0-indexed month
calendar.time.day = calendar_time.day;
calendar.time.hour = calendar_time.hour;
calendar.time.minute = calendar_time.minute;
@@ -874,7 +874,7 @@ ResultCode TimeZoneManager::ToPosixTime(const TimeZoneRule& rules,
CalendarTimeInternal internal_time{};
internal_time.year = calendar_time.year;
- internal_time.month = calendar_time.month;
+ internal_time.month = calendar_time.month - 1; // Internal impl. uses 0-indexed month
internal_time.day = calendar_time.day;
internal_time.hour = calendar_time.hour;
internal_time.minute = calendar_time.minute;