]> git.proxmox.com Git - grub2.git/commit
font: Fix integer overflow in ensure_comb_space()
authorZhang Boyang <zhangboyang.id@gmail.com>
Thu, 4 Aug 2022 18:27:05 +0000 (02:27 +0800)
committerSteve McIntyre <93sam@debian.org>
Sat, 12 Nov 2022 22:51:49 +0000 (22:51 +0000)
commit96409d679abf693d09d5683203b7fa20c70c6ac8
tree2c411fd140c3c783c00376c0f9c2c9b92c3eb47d
parentabce8a8ff6997cdf33a6ca6f77dccd0e00c65650
font: Fix integer overflow in ensure_comb_space()

In fact it can't overflow at all because glyph_id->ncomb is only 8-bit
wide. But let's keep safe if somebody changes the width of glyph_id->ncomb
in the future. This patch also fixes the inconsistency between
render_max_comb_glyphs and render_combining_glyphs when grub_malloc()
returns NULL.

Signed-off-by: Zhang Boyang <zhangboyang.id@gmail.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
debian/patches/cve_2022_2601/0006-font-Fix-integer-overflow-in-ensure_comb_space.patch [new file with mode: 0644]
grub-core/font/font.c