grub2/grub-core/normal
Carlos Maiolino 81f1962393 fs: Use 64-bit type for filesystem timestamp
Some filesystems nowadays use 64-bit types for timestamps. So, update
grub_dirhook_info struct to use an grub_int64_t type to store mtime.
This also updates the grub_unixtime2datetime() function to receive
a 64-bit timestamp argument and do 64-bit-safe divisions.

All the remaining conversion from 32-bit to 64-bit should be safe, as
32-bit to 64-bit attributions will be implicitly casted. The most
critical part in the 32-bit to 64-bit conversion is in the function
grub_unixtime2datetime() where it needs to deal with the 64-bit type.
So, for that, the grub_divmod64() helper has been used.

These changes enables the GRUB to support dates beyond y2038.

Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com>
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
2021-06-01 17:19:13 +02:00
..
auth.c core: use GRUB_TERM_ definitions when handling term characters 2017-08-07 19:28:22 +02:00
autofs.c verifiers: File type for fine-grained signature-verification controlling 2018-11-09 13:25:31 +01:00
charset.c malloc: Use overflow checking primitives where we do complex allocations 2020-07-29 16:55:47 +02:00
cmdline.c malloc: Use overflow checking primitives where we do complex allocations 2020-07-29 16:55:47 +02:00
color.c Replace explicit sizeof divisions by ARRAY_SIZE. 2015-01-21 17:37:31 +01:00
completion.c normal/completion: Fix leaking of memory when processing a completion 2021-03-02 15:54:17 +01:00
context.c normal: fix memory leak 2015-06-20 23:38:19 +03:00
crypto.c verifiers: File type for fine-grained signature-verification controlling 2018-11-09 13:25:31 +01:00
dyncmd.c verifiers: File type for fine-grained signature-verification controlling 2018-11-09 13:25:31 +01:00
main.c normal/main: Search for specific config files for netboot 2020-02-18 15:12:06 +01:00
menu_entry.c malloc: Use overflow checking primitives where we do complex allocations 2020-07-29 16:55:47 +02:00
menu_text.c calloc: Use calloc() at most places 2020-07-29 16:55:47 +02:00
menu.c kern/term: Accept ESC, F4 and holding SHIFT as user interrupt keys 2020-04-21 22:13:44 +02:00
misc.c fs: Use 64-bit type for filesystem timestamp 2021-06-01 17:19:13 +02:00
term.c calloc: Use calloc() at most places 2020-07-29 16:55:47 +02:00