summaryrefslogtreecommitdiff
path: root/MdeModulePkg
diff options
context:
space:
mode:
authorStar Zeng <star.zeng@intel.com>2013-11-19 05:42:51 +0000
committerlzeng14 <lzeng14@6f19259b-4bc3-4df7-8a09-765794883524>2013-11-19 05:42:51 +0000
commit7df095713ad520121da7a4eae9bf8e089a5fd5e4 (patch)
tree3ef0b4e680efbf35b55446592edaa04ebf3ba103 /MdeModulePkg
parent38d91622fa49111d65532c6ba19458daef8de4d4 (diff)
downloadedk2-7df095713ad520121da7a4eae9bf8e089a5fd5e4.zip
edk2-7df095713ad520121da7a4eae9bf8e089a5fd5e4.tar.gz
edk2-7df095713ad520121da7a4eae9bf8e089a5fd5e4.tar.bz2
MdeModulePkg Pcd: Refine the code to avoid error report.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14861 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg')
-rw-r--r--MdeModulePkg/Universal/PCD/Dxe/Service.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/MdeModulePkg/Universal/PCD/Dxe/Service.c b/MdeModulePkg/Universal/PCD/Dxe/Service.c
index 513402c..4bdb071 100644
--- a/MdeModulePkg/Universal/PCD/Dxe/Service.c
+++ b/MdeModulePkg/Universal/PCD/Dxe/Service.c
@@ -501,6 +501,7 @@ BuildPcdDxeDataBase (
ASSERT(mPcdDatabase.DxeDb != NULL);
PcdDxeDbLen = mPcdDatabase.DxeDb->Length + mPcdDatabase.DxeDb->UninitDataBaseSize;
PcdDxeDb = AllocateZeroPool (PcdDxeDbLen);
+ ASSERT (PcdDxeDb != NULL);
CopyMem (PcdDxeDb, mPcdDatabase.DxeDb, mPcdDatabase.DxeDb->Length);
FreePool (mPcdDatabase.DxeDb);
mPcdDatabase.DxeDb = PcdDxeDb;