From e6c4ef13363d9a808edd4eb758b573f4d00bc272 Mon Sep 17 00:00:00 2001 From: jji4 Date: Fri, 16 Jan 2009 08:14:39 +0000 Subject: [PATCH] Source level security checked git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7297 6f19259b-4bc3-4df7-8a09-765794883524 --- MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c index 745021a0f3..553ae2824d 100644 --- a/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c +++ b/MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c @@ -141,6 +141,7 @@ UpdateVariableInfo ( CopyGuid (&gVariableInfo->VendorGuid, VendorGuid); gVariableInfo->Name = AllocatePool (StrLen (VariableName)); + ASSERT (gVariableInfo->Name != NULL); StrCpy (gVariableInfo->Name, VariableName); gVariableInfo->Volatile = Volatile; @@ -178,6 +179,7 @@ UpdateVariableInfo ( CopyGuid (&Entry->Next->VendorGuid, VendorGuid); Entry->Next->Name = AllocatePool (StrLen (VariableName)); + ASSERT (Entry->Next->Name != NULL); StrCpy (Entry->Next->Name, VariableName); Entry->Next->Volatile = Volatile; }