Reviewed-by: jiewen....@intel.com
> -----Original Message----- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of Star > Zeng > Sent: Monday, April 16, 2018 4:42 PM > To: edk2-devel@lists.01.org > Cc: Yao, Jiewen <jiewen....@intel.com>; Zeng, Star <star.z...@intel.com> > Subject: [edk2] [PATCH] MdeModulePkg DxeCapsuleLibFmp: Fix wrong Index is > used > > DEBUG(( > DEBUG_ERROR, > "ItemOffsetList[%d](0x%lx) < ItemOffsetList[%d](0x%x)\n", > Index, > ItemOffsetList[Index], > Index, // Should be Index - 1 > ItemOffsetList[Index - 1] > )); > > Cc: Jiewen Yao <jiewen....@intel.com> > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Star Zeng <star.z...@intel.com> > --- > MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.c > b/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.c > index 36e8c26aa976..a5dcb76d5aaa 100644 > --- a/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.c > +++ b/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.c > @@ -250,7 +250,7 @@ ValidateFmpCapsule ( > // > if (Index > 0) { > if (ItemOffsetList[Index] <= ItemOffsetList[Index - 1]) { > - DEBUG((DEBUG_ERROR, "ItemOffsetList[%d](0x%lx) < > ItemOffsetList[%d](0x%x)\n", Index, ItemOffsetList[Index], Index, > ItemOffsetList[Index - 1])); > + DEBUG((DEBUG_ERROR, "ItemOffsetList[%d](0x%lx) < > ItemOffsetList[%d](0x%x)\n", Index, ItemOffsetList[Index], Index - 1, > ItemOffsetList[Index - 1])); > return EFI_INVALID_PARAMETER; > } > } > -- > 2.7.0.windows.1 > > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel