From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Andrei Borzenkov <arvidjaar@gmail.com>
Date: Sat, 20 Jun 2015 23:38:17 +0300
Subject: [PATCH] efi/chainloader: fix use after free
Found by: Coverity scan.
CID: 96714
---
grub-core/loader/efi/chainloader.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/grub-core/loader/efi/chainloader.c b/grub-core/loader/efi/chainloader.c
index 233237018b5..ec23cf4ed66 100644
--- a/grub-core/loader/efi/chainloader.c
+++ b/grub-core/loader/efi/chainloader.c
@@ -351,6 +351,7 @@ grub_cmd_chainloader (grub_command_t cmd __attribute__ ((unused)),
loaded_image->device_handle = dev_handle;
grub_file_close (file);
+ file = NULL;
if (argc > 1)
{