On 2026-09-30T08:52:14, Suraj Kakade <[email protected]> wrote: > boot: pxe_utils: Fix leak and double free when using fallback > > When use_fallback is set and the config defines a fallback label, > parse_pxefile() assigns fallback_label to default_label. The previous > default_label allocation is not freed, so that string is leaked. Both > members then point at the same buffer, and destroy_pxe_menu() frees it > twice. > > Free the previous default_label and clear fallback_label so only one > member owns the string. > > Fixes: 8ba82a91b3aa ("boot: Add logic to enable booting from fallback option") > Signed-off-by: Suraj Kakade <[email protected]> > > boot/pxe_utils.c | 2 ++ > 1 file changed, 2 insertions(+)
Reviewed-by: Simon Glass <[email protected]>
