From c069460259b0a3ed77c4035267250dc2b82f1cb4 Mon Sep 17 00:00:00 2001 From: Andrei Borzenkov 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 233237018..ec23cf4ed 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) {