From 471ea9ad4690677cbda2ca6aac7ba1d6f3aa3348 Mon Sep 17 00:00:00 2001 From: vit9696 <4348897+vit9696@users.noreply.github.com> Date: Mon, 2 Mar 2020 09:18:28 +0300 Subject: [PATCH] OcBootManagementLib: Skip CurrentPolicy for cleaner log --- Library/OcBootManagementLib/VariableManagement.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Library/OcBootManagementLib/VariableManagement.c b/Library/OcBootManagementLib/VariableManagement.c index b4be6a2ca29..8eeb0a053f4 100644 --- a/Library/OcBootManagementLib/VariableManagement.c +++ b/Library/OcBootManagementLib/VariableManagement.c @@ -112,7 +112,12 @@ IsDeletableVariable ( // Microsoft certificates if present // } else if (CompareGuid (Guid, &gMicrosoftVariableGuid)) { - return TRUE; + // + // Do not remove current OEM policy. + // + if (StrCmp (Name, L"CurrentPolicy") != 0) { + return TRUE; + } } return FALSE;