time: Change signature of get_jdn() to use int types

This commit is contained in:
mintsuki 2023-09-28 00:51:24 -05:00
parent dbd145b6c4
commit 33f238fb3f
1 changed files with 1 additions and 1 deletions

View File

@ -9,7 +9,7 @@
#include <lib/misc.h>
// Julian date calculation from https://en.wikipedia.org/wiki/Julian_day
static uint64_t get_jdn(uint8_t days, uint8_t months, uint16_t years) {
static int get_jdn(int days, int months, int years) {
return (1461 * (years + 4800 + (months - 14)/12))/4 + (367 *
(months - 2 - 12 * ((months - 14)/12)))/12 -
(3 * ((years + 4900 + (months - 14)/12)/100))/4