diff options
author | eric_tian <eric_tian@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-03-18 06:47:55 +0000 |
---|---|---|
committer | eric_tian <eric_tian@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-03-18 06:47:55 +0000 |
commit | de631489deaebcdf5e3bc702ea7c8c28586b9c8c (patch) | |
tree | a4d534d21674301609ae811a66c57d01818ab7c4 | |
parent | 01f352a7ca57e2bc5ed0f72e5b1d50b6de4469ed (diff) | |
download | edk2-de631489deaebcdf5e3bc702ea7c8c28586b9c8c.zip edk2-de631489deaebcdf5e3bc702ea7c8c28586b9c8c.tar.gz edk2-de631489deaebcdf5e3bc702ea7c8c28586b9c8c.tar.bz2 |
[Description]
PeiGetVariable() and PeiGetNextVariableName() do not check NULL pointer access, not follow spec
[Impaction]
modify the Variable.c file in IntelFrameworkModulePkg/Universal/VariablePei/
[Reference Info]
PeiGetVariable() and PeiGetVariableName() do not follow spec
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4900 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r-- | IntelFrameworkModulePkg/Universal/VariablePei/Variable.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c index 8fc6749..0b9fa29 100644 --- a/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c +++ b/IntelFrameworkModulePkg/Universal/VariablePei/Variable.c @@ -1,6 +1,6 @@ /*++
-Copyright (c) 2006 - 2007 Intel Corporation. <BR>
+Copyright (c) 2006 - 2008 Intel Corporation. <BR>
All rights reserved. This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -598,7 +598,7 @@ Returns: UINTN VarDataSize;
EFI_STATUS Status;
- if (VariableName == NULL || VendorGuid == NULL) {
+ if (VariableName == NULL || VendorGuid == NULL || DataSize == NULL) {
return EFI_INVALID_PARAMETER;
}
//
@@ -725,7 +725,7 @@ Returns: UINTN VarNameSize;
EFI_STATUS Status;
- if (VariableName == NULL) {
+ if (VariableNameSize == NULL || VariableName == NULL || VendorGuid == NULL) {
return EFI_INVALID_PARAMETER;
}
|