When CustomCumulativeToken is not NULL, the CustomCumulativeData is expected non-NULL.
Add 'ASSERT' statement to ensure this.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Qiu Shumin <shumin.qiu@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18955
6f19259b-4bc3-4df7-8a09-
765794883524
Dp uses this information to group records in different ways. It also uses\r
timer information to calculate elapsed time for each measurement.\r
\r
Dp uses this information to group records in different ways. It also uses\r
timer information to calculate elapsed time for each measurement.\r
\r
- Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>\r
+ Copyright (c) 2009 - 2015, Intel Corporation. All rights reserved.<BR>\r
(C) Copyright 2015 Hewlett Packard Enterprise Development LP<BR>\r
This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
(C) Copyright 2015 Hewlett Packard Enterprise Development LP<BR>\r
This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
CustomCumulativeToken = ShellCommandLineGetValue (ParamPackage, StringDpOptionLc);\r
if (CustomCumulativeToken != NULL) {\r
CustomCumulativeData = AllocateZeroPool (sizeof (PERF_CUM_DATA));\r
CustomCumulativeToken = ShellCommandLineGetValue (ParamPackage, StringDpOptionLc);\r
if (CustomCumulativeToken != NULL) {\r
CustomCumulativeData = AllocateZeroPool (sizeof (PERF_CUM_DATA));\r
+ ASSERT (CustomCumulativeData != NULL);\r
CustomCumulativeData->MinDur = 0;\r
CustomCumulativeData->MaxDur = 0;\r
CustomCumulativeData->Count = 0;\r
CustomCumulativeData->MinDur = 0;\r
CustomCumulativeData->MaxDur = 0;\r
CustomCumulativeData->Count = 0;\r