Alec Brown 5b36a5210e normal/menu: Use safe math to avoid an integer overflow
The Coverity indicates that the variable current_entry might overflow.
To prevent this use safe math when adding GRUB_MENU_PAGE_SIZE to current_entry.

On the occasion fix limiting condition which was broken.

Fixes: CID 473853

Signed-off-by: Alec Brown <alec.r.brown@oracle.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
2025-02-13 15:45:58 +01:00
..
2022-03-14 15:58:27 +01:00
2022-03-14 15:58:27 +01:00
2022-03-14 15:58:27 +01:00
2022-03-14 15:58:27 +01:00