From: Star Zeng Date: Fri, 28 Mar 2014 02:47:46 +0000 (+0000) Subject: SecurityPkg Variable: Add NULL pointer check. X-Git-Tag: edk2-stable201903~11569 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=3a4b498ee1f10d2ed7ac4f29f99d69d1abb9f24b SecurityPkg Variable: Add NULL pointer check. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng Reviewed-by: Guo Dong git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15409 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/SecurityPkg/VariableAuthenticated/RuntimeDxe/Variable.c b/SecurityPkg/VariableAuthenticated/RuntimeDxe/Variable.c index 7d7bc9e0e1..6a33a78da4 100644 --- a/SecurityPkg/VariableAuthenticated/RuntimeDxe/Variable.c +++ b/SecurityPkg/VariableAuthenticated/RuntimeDxe/Variable.c @@ -860,6 +860,7 @@ Reclaim ( if (EFI_ERROR (Status)) { goto Done; } + ASSERT ((NewPubKeyIndex != NULL) && (NewPubKeyStore != NULL)); // // Refresh the PubKeyIndex for all valid variables (ADDED and IN_DELETED_TRANSITION).