Revision: 13977
http://edk2.svn.sourceforge.net/edk2/?rev=13977&view=rev
Author: lzeng14
Date: 2012-11-29 01:19:20 +0000 (Thu, 29 Nov 2012)
Log Message:
-----------
Use mS3BootScriptTablePtr->TableLength + sizeof (EFI_BOOT_SCRIPT_TERMINATE) to
get the correct table length.
Signed-off-by: Star Zeng <[email protected]>
Reviewed-by: Jiewen Yao <[email protected]>
Modified Paths:
--------------
trunk/edk2/MdeModulePkg/Library/PiDxeS3BootScriptLib/BootScriptSave.c
Modified: trunk/edk2/MdeModulePkg/Library/PiDxeS3BootScriptLib/BootScriptSave.c
===================================================================
--- trunk/edk2/MdeModulePkg/Library/PiDxeS3BootScriptLib/BootScriptSave.c
2012-11-28 08:49:21 UTC (rev 13976)
+++ trunk/edk2/MdeModulePkg/Library/PiDxeS3BootScriptLib/BootScriptSave.c
2012-11-29 01:19:20 UTC (rev 13977)
@@ -1989,13 +1989,10 @@
if (RelativePosition == NULL) {
return EFI_INVALID_PARAMETER;
}
- TableLength = ((EFI_BOOT_SCRIPT_TABLE_HEADER*)Script)->TableLength;
//
- // If in boot time, TableLength does not include the termination node. so
add it up
+ // mS3BootScriptTablePtr->TableLength does not include the termination node,
so add it up
//
- if (!mS3BootScriptTablePtr->AtRuntime) {
- TableLength += sizeof(EFI_BOOT_SCRIPT_TERMINATE);
- }
+ TableLength = mS3BootScriptTablePtr->TableLength + sizeof
(EFI_BOOT_SCRIPT_TERMINATE);
if (Position1 < Script || Position1 > Script+TableLength) {
return EFI_INVALID_PARAMETER;
}
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Keep yourself connected to Go Parallel:
VERIFY Test and improve your parallel project with help from experts
and peers. http://goparallel.sourceforge.net
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits