tz_offset should be treated as float when down casting calculation result to int32

This commit is contained in:
liamcottle committed 2026-10-17 15:22:46 +13:00
1 parent 7a0fde2912
commit 0e63c183a8
1 file changed
+1 -1
+1 -1
View File
@@ -295,7 +295,7 @@ public:
#ifdef UI_SHOW_CLOCK
display.setTextSize(3);
uint32_t now = _rtc->getCurrentTime();
now += (int32_t)_node_prefs->tz_offset * 3600;
now += (int32_t)(_node_prefs->tz_offset * 3600);
DateTime dt (now);
sprintf(tmp, "%02d:%02d", dt.hour(), dt.minute());
display.drawTextCentered(display.width() / 2, 60, tmp);