mirror of https://github.com/acidanthera/audk.git
PerformancePkg/Dp_App: Add check to avoid NULL pointer deference
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com>
This commit is contained in:
parent
14e3b94964
commit
9555c09717
|
@ -400,7 +400,7 @@ InitializeDp (
|
|||
// EndCount = Value counter counts to before it needs to be reset
|
||||
//
|
||||
Status = EfiGetSystemConfigurationTable (&gPerformanceProtocolGuid, (VOID **) &PerformanceProperty);
|
||||
if (EFI_ERROR (Status)) {
|
||||
if (EFI_ERROR (Status) || (PerformanceProperty == NULL)) {
|
||||
PrintToken (STRING_TOKEN (STR_PERF_PROPERTY_NOT_FOUND));
|
||||
goto Done;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue