summaryrefslogtreecommitdiffstats
path: root/MdeModulePkg/Application
diff options
context:
space:
mode:
authorStar Zeng <star.zeng@intel.com>2018-07-19 11:03:25 +0800
committerStar Zeng <star.zeng@intel.com>2018-07-27 16:04:13 +0800
commit23d083341764b5645b86e14d0451a2e012ded357 (patch)
treeb00f6bb3380db7a8d5c2e8c2d911a1588128f92d /MdeModulePkg/Application
parent4436f72220aa59eda7f811abb5ca926efc269f16 (diff)
downloadedk2-23d083341764b5645b86e14d0451a2e012ded357.tar.gz
edk2-23d083341764b5645b86e14d0451a2e012ded357.tar.bz2
edk2-23d083341764b5645b86e14d0451a2e012ded357.zip
MdeModulePkg CapsuleApp: Fix -D failed to dump Nest FMP capsule
Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Yonghong Zhu <yonghong.zhu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Diffstat (limited to 'MdeModulePkg/Application')
-rw-r--r--MdeModulePkg/Application/CapsuleApp/CapsuleDump.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c b/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c
index 97f1893ef4..4c85e8c23d 100644
--- a/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c
+++ b/MdeModulePkg/Application/CapsuleApp/CapsuleDump.c
@@ -214,7 +214,7 @@ IsNestedFmpCapsule (
// FMP GUID after ESRT one
//
NestedCapsuleHeader = (EFI_CAPSULE_HEADER *)((UINT8 *)CapsuleHeader + CapsuleHeader->HeaderSize);
- NestedCapsuleSize = (UINTN)CapsuleHeader + CapsuleHeader->HeaderSize - (UINTN)NestedCapsuleHeader;
+ NestedCapsuleSize = (UINTN)CapsuleHeader + CapsuleHeader->CapsuleImageSize- (UINTN)NestedCapsuleHeader;
if (NestedCapsuleSize < sizeof(EFI_CAPSULE_HEADER)) {
return FALSE;
}