diff options
-rw-r--r-- | IntelFrameworkModulePkg/Universal/VariablePei/Variable.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c index 72d8fd1252..8fc67499fb 100644 --- a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c +++ b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c @@ -614,6 +614,13 @@ Returns: //
VarDataSize = DataSizeOfVariable (Variable.CurrPtr);
if (*DataSize >= VarDataSize) {
+ //
+ // PO-TKW: Address one checking in this place
+ //
+ if (Data == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
(*PeiServices)->CopyMem (Data, GetVariableDataPtr (Variable.CurrPtr), VarDataSize);
if (Attributes != NULL) {
|