From 562f85685daa0aed7d98c591d39b8784e5519021 Mon Sep 17 00:00:00 2001 From: vit9696 Date: Wed, 14 Apr 2021 01:31:21 +0300 Subject: [PATCH] OcDeviceMiscLib: Fix another NULL free --- Library/OcDeviceMiscLib/ReloadOptionRoms.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Library/OcDeviceMiscLib/ReloadOptionRoms.c b/Library/OcDeviceMiscLib/ReloadOptionRoms.c index 3835a38c..8aca8f3b 100644 --- a/Library/OcDeviceMiscLib/ReloadOptionRoms.c +++ b/Library/OcDeviceMiscLib/ReloadOptionRoms.c @@ -252,9 +252,13 @@ OcReloadOptionRoms ( } } - FreePool (BindingHandleBuffer); + if (BindingHandleBuffer != NULL) { + FreePool (BindingHandleBuffer); + } } } + FreePool (HandleArray); + return ReturnStatus; }