Hi,

This patch is a minor issue, but in terms of correctness I think this
free is missing.

Happy hacking,
Miguel
>From 1720e89de777fd3a30a6824797d97855b7bb8b68 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?=
 <rosen644...@gmail.com>
Date: Mon, 28 Oct 2019 10:08:25 +0100
Subject: [PATCH 1/2] install: Free allocated path for grub.efi.

* util/grub-install.c (main): Free local variable allocated with
grub_util_path_concat.
---
 util/grub-install.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/util/grub-install.c b/util/grub-install.c
index 8970b73aa..8f84bf8cd 100644
--- a/util/grub-install.c
+++ b/util/grub-install.c
@@ -1664,6 +1664,7 @@ main (int argc, char *argv[])
 				       /* memdisk */ NULL,
 				      have_load_cfg ? load_cfg : NULL,
 				       /* image target */ mkimage_target, 0);
+	free (dst);
       }
       break;
     case GRUB_INSTALL_PLATFORM_ARM_EFI:
-- 
2.23.0

_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to