Reviewed-by: [email protected] > -----Original Message----- > From: Wu, Hao A > Sent: Friday, January 6, 2017 4:56 PM > To: [email protected] > Cc: Wu, Hao A <[email protected]>; Zhang, Chao B <[email protected]>; > Yao, Jiewen <[email protected]> > Subject: [PATCH] SignedCapsulePkg/CapsuleLib: Refine to compare with same > type > > Cc: Chao Zhang <[email protected]> > Cc: Jiewen Yao <[email protected]> > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Hao Wu <[email protected]> > --- > .../Library/EdkiiSystemCapsuleLib/EdkiiSystemCapsuleLib.c | 4 > ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git > a/SignedCapsulePkg/Library/EdkiiSystemCapsuleLib/EdkiiSystemCapsuleLib.c > b/SignedCapsulePkg/Library/EdkiiSystemCapsuleLib/EdkiiSystemCapsuleLib.c > index 1820551..dfd8d10 100644 > --- a/SignedCapsulePkg/Library/EdkiiSystemCapsuleLib/EdkiiSystemCapsuleLib.c > +++ > b/SignedCapsulePkg/Library/EdkiiSystemCapsuleLib/EdkiiSystemCapsuleLib.c > @@ -6,7 +6,7 @@ > CapsuleAuthenticateSystemFirmware(), ExtractAuthenticatedImage() will > receive > untrusted input and do basic validation. > > - Copyright (c) 2016, Intel Corporation. All rights reserved.<BR> > + Copyright (c) 2016 - 2017, 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 > @@ -386,7 +386,7 @@ ExtractAuthenticatedImage ( > DEBUG((DEBUG_ERROR, "ExtractAuthenticatedImage - dwLength too > small\n")); > return FALSE; > } > - if (ImageAuth->AuthInfo.Hdr.dwLength > MAX_UINTN - sizeof(UINT64)) { > + if ((UINTN) ImageAuth->AuthInfo.Hdr.dwLength > MAX_UINTN - > sizeof(UINT64)) { > DEBUG((DEBUG_ERROR, "ExtractAuthenticatedImage - dwLength too > big\n")); > return FALSE; > } > -- > 1.9.5.msysgit.0
_______________________________________________ edk2-devel mailing list [email protected] https://lists.01.org/mailman/listinfo/edk2-devel

