On 14.07.2025 15:26, Dmytro Prokopchuk1 wrote:
> --- a/xen/common/time.c
> +++ b/xen/common/time.c
> @@ -84,7 +84,7 @@ struct tm gmtime(unsigned long t)
>      }
>      tbuf.tm_year = y - 1900;
>      tbuf.tm_yday = days;
> -    ip = (const unsigned short int *)__mon_lengths[__isleap(y)];
> +    ip = (const unsigned short int *)__mon_lengths[__isleap(y) ? 1 : 0];

Oh, and: This cast is one of the more dangerous ones, and afaict it's entirely
pointless. When touching this line, I think the cast would want removing at the
same time.

Jan

Reply via email to