Re: [PATCH] blsuki: Fix grub_errno leakage in blsuki_is_default_entry()

Michael Chang via Grub-devel <[email protected]>
Newsgroups org.gnu.grub-devel
Message-ID <n5xb3b3ezh7eq5obogyf7tlwi35ixvuaonfidomxyvrhhp2qm5@p5cm2fjrhrur>
On Mon, Nov 10, 2025 at 08:34:18PM +0530, Avnish Chouhan wrote:
> On 2025-11-10 19:06, [email protected] wrote:
> > Message: 3
> > Date: Mon, 10 Nov 2025 15:38:13 +0800
> > From: Michael Chang <[email protected]>
> > To: The development of GNU GRUB <[email protected]>
> > Subject: [PATCH] blsuki: Fix grub_errno leakage in
> > 	blsuki_is_default_entry()
> > Message-ID: <[email protected]>
> > 
> > The grub_strtol() call in blsuki_is_default_entry() can set grub_errno
> > to GRUB_ERR_BAD_NUMBER if the input string cannot be converted into any
> > valid digits.
> > 
> > This errno value is currently left uncleared, which can lead to
> > unexpected behavior in subsequent logic that tests the result of a
> > function by checking grub_errno.
> > 
> > Clear grub_errno and return false when GRUB_ERR_BAD_NUMBER is set, as
> > this specific error should be ignored in this context.
> > 
> > Signed-off-by: Michael Chang <[email protected]>
> 
> Reviewed-by: Avnish Chouhan <[email protected]>

Thanks a lot for the review. I'll add your Reviewed-by tag in next
version.

Thanks,
Michael

> 
> Regards,
> Avnish Chouhan

_______________________________________________
Grub-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/grub-devel
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.