summaryrefslogtreecommitdiff
path: root/MdePkg/Library/BaseLib/X86FxRestore.c
diff options
context:
space:
mode:
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2012-10-30 08:35:08 +0000
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2012-10-30 08:35:08 +0000
commit2054fd132a4ffd9cb2dcdcece691c5f5db9b9b4e (patch)
tree5cd7910f5cb102a87d1b671909d9e250143e9de1 /MdePkg/Library/BaseLib/X86FxRestore.c
parent73a324f8014fbe68d4fe947287da4e5d4dea31fb (diff)
downloadedk2-platforms-2054fd132a4ffd9cb2dcdcece691c5f5db9b9b4e.tar.xz
Fix memory out of band access in AsmFxSave() and AsmFxRestore().
Signed-off-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Feng Tian <feng.tian@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13894 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg/Library/BaseLib/X86FxRestore.c')
-rw-r--r--MdePkg/Library/BaseLib/X86FxRestore.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/MdePkg/Library/BaseLib/X86FxRestore.c b/MdePkg/Library/BaseLib/X86FxRestore.c
index d93cc91df3..b2a02fe25f 100644
--- a/MdePkg/Library/BaseLib/X86FxRestore.c
+++ b/MdePkg/Library/BaseLib/X86FxRestore.c
@@ -1,7 +1,7 @@
/** @file
IA-32/x64 AsmFxRestore()
- Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
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
@@ -43,7 +43,7 @@ AsmFxRestore (
//
// Check the flag recorded by AsmFxSave()
//
- ASSERT (0xAA5555AA == *(UINT32 *) (&Buffer[sizeof (IA32_FX_BUFFER) - 4]));
+ ASSERT (0xAA5555AA == *(UINT32 *) (&Buffer->Buffer[sizeof (Buffer->Buffer) - 4]));
InternalX86FxRestore (Buffer);
}