Add the check- in missed file

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4674 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
gtian 2008-02-04 19:51:45 +00:00
parent 7adf5fa455
commit fd431a9b3f
1 changed files with 7 additions and 0 deletions

View File

@ -614,6 +614,13 @@ Returns:
// //
VarDataSize = DataSizeOfVariable (Variable.CurrPtr); VarDataSize = DataSizeOfVariable (Variable.CurrPtr);
if (*DataSize >= VarDataSize) { 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); (*PeiServices)->CopyMem (Data, GetVariableDataPtr (Variable.CurrPtr), VarDataSize);
if (Attributes != NULL) { if (Attributes != NULL) {