ieee1275/ofnet: Fix grub_malloc() removed after added safe
Resolves: #RHEL-83117 Signed-off-by: Nicolas Frayer <nfrayer@redhat.com>
This commit is contained in:
parent
04bc7689d6
commit
12da33fad6
@ -0,0 +1,32 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Nicolas Frayer <nfrayer@redhat.com>
|
||||
Date: Wed, 19 Mar 2025 17:39:41 +0100
|
||||
Subject: [PATCH] ieee1275/ofnet: Fix grub_malloc() removed after added safe
|
||||
math functions
|
||||
|
||||
grub_malloc() has been inadvertently removed from the ieee1275/ofnet
|
||||
code after it has been modified to use safe match function.
|
||||
|
||||
Fixes: 4beeff8a (net: Use safe math macros to prevent overflows)
|
||||
|
||||
Tested-by: Marta Lewandowska <mlewando@redhat.com>
|
||||
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
|
||||
Signed-off-by: Nicolas Frayer <nfrayer@redhat.com>
|
||||
---
|
||||
grub-core/net/drivers/ieee1275/ofnet.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/grub-core/net/drivers/ieee1275/ofnet.c b/grub-core/net/drivers/ieee1275/ofnet.c
|
||||
index 3e1b9094e2ab..37bc82467f60 100644
|
||||
--- a/grub-core/net/drivers/ieee1275/ofnet.c
|
||||
+++ b/grub-core/net/drivers/ieee1275/ofnet.c
|
||||
@@ -463,6 +463,9 @@ search_net_devices (struct grub_ieee1275_devalias *alias)
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
+
|
||||
+ ofdata->path = grub_malloc(sz);
|
||||
+
|
||||
if (!ofdata->path)
|
||||
{
|
||||
grub_print_error ();
|
@ -453,3 +453,4 @@ Patch0453: 0453-fs-xfs-Fix-issues-found-while-fuzzing-the-XFS-filesy.patch
|
||||
Patch0454: 0454-fs-ext2-Rework-out-of-bounds-read-for-inline-and-ext.patch
|
||||
Patch0455: 0455-tpm-Disable-the-tpm-verifier-if-the-TPM-device-is-no.patch
|
||||
Patch0456: 0456-powerpc-increase-MIN-RMA-size-for-CAS-negotiation.patch
|
||||
Patch0457: 0457-ieee1275-ofnet-Fix-grub_malloc-removed-after-added-s.patch
|
||||
|
@ -16,7 +16,7 @@
|
||||
Name: grub2
|
||||
Epoch: 1
|
||||
Version: 2.06
|
||||
Release: 99%{?dist}
|
||||
Release: 100%{?dist}
|
||||
Summary: Bootloader with support for Linux, Multiboot and more
|
||||
License: GPLv3+
|
||||
URL: http://www.gnu.org/software/grub/
|
||||
@ -547,6 +547,10 @@ mv ${EFI_HOME}/grub.cfg.stb ${EFI_HOME}/grub.cfg
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Tue Mar 25 2025 Nicolas Frayer <nfrayer@redhat.com> 2.06-100
|
||||
- ieee1275/ofnet: Fix grub_malloc() removed after added safe
|
||||
- Resolves: #RHEL-83117
|
||||
|
||||
* Mon Mar 17 2025 Nicolas Frayer <nfrayer@redhat.com> 2.06-99
|
||||
- Added the following 2 commits to optimize memory consumption
|
||||
- tpm: Disable the tpm verifier if the TPM device is not present
|
||||
|
Loading…
Reference in New Issue
Block a user