diff --git a/Clean-up-redundant-code.patch b/Clean-up-redundant-code.patch new file mode 100644 index 0000000000000000000000000000000000000000..a75f8baadb5aa61503e157983bb6e2c01082fcb9 --- /dev/null +++ b/Clean-up-redundant-code.patch @@ -0,0 +1,24 @@ +From 225a7e36ff703a63f5caf04d0ec8d84e0386c845 Mon Sep 17 00:00:00 2001 +From: openEuler Buildteam +Date: Fri, 10 May 2024 17:32:32 +0800 +Subject: [PATCH] Clean up redundant code + +--- + grub-core/fs/jfs.c | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/grub-core/fs/jfs.c b/grub-core/fs/jfs.c +index 6f7c439..62e20ef 100644 +--- a/grub-core/fs/jfs.c ++++ b/grub-core/fs/jfs.c +@@ -716,7 +716,6 @@ grub_jfs_find_file (struct grub_jfs_data *data, const char *path, + grub_uint32_t dirino = grub_le_to_cpu32 (data->currinode.inode); + + grub_jfs_closedir (diro); +- diro = 0; + + if (grub_jfs_read_inode (data, ino, &data->currinode)) + break; +-- +2.33.0 + diff --git a/grub.patches b/grub.patches index 97ff02778c2342aeeb4db466846eb243f0d55cac..fc912d2da942309c2d59a4d07e5386d6e513fd0b 100644 --- a/grub.patches +++ b/grub.patches @@ -227,3 +227,4 @@ Patch226: 0038-Add-grub-get-kernel-settings-and-use-it-in-10_linux.patch Patch227: 0084-grub-editenv-Add-incr-command-to-increment-integer-v.patch Patch228: 0002-Revert-templates-Properly-disable-the-os-prober-by-d.patch Patch229: 0003-Revert-templates-Disable-the-os-prober-by-default.patch +Patch230: Clean-up-redundant-code.patch diff --git a/grub2.spec b/grub2.spec index 96d5b6e6dcc93d503af47093ca61a46d33fb65a9..920bc0677a0b66aad081d5927337eaf50d6644db 100644 --- a/grub2.spec +++ b/grub2.spec @@ -14,7 +14,7 @@ Name: grub2 Epoch: 1 Version: 2.12 -Release: 9 +Release: 10 Summary: Bootloader with support for Linux, Multiboot and more License: GPLv3+ URL: http://www.gnu.org/software/grub/ @@ -447,6 +447,15 @@ fi %{_datadir}/man/man* %changelog +* Fri May 10 2024 xiaozai - 1:2.12-10 +- Type:enhancement +- CVE:NA +- SUG:NA +- DESC:Clean up redundant code + In grub-core/fs/jfs.c, Coverity spotted redundant code where the pointer diro + was being set to 0 and then being overwritten later without being used. Since + this is unnecessary, we can remove the code that sets diro to 0. + * Tue May 7 2024 zhangqiumiao - 1:2.12-9 - Type:bugfix - CVE:NA