Reviewed-by: Bret Barkelew <[email protected]> - Bret
________________________________ From: [email protected] <[email protected]> on behalf of Michael D Kinney via Groups.Io <[email protected]> Sent: Monday, March 23, 2020 10:32:59 AM To: Jiang, Guomin <[email protected]>; [email protected] <[email protected]>; Zhang, Shenglei <[email protected]>; [email protected] <[email protected]>; Kinney, Michael D <[email protected]> Cc: Sean Brogan <[email protected]>; Bret Barkelew <[email protected]> Subject: [EXTERNAL] Re: [edk2-devel] [PATCH] UnitTestFrameworkPkg: Invalid index may be used. Reviewed-by: Michael D Kinney <[email protected]> Mike > -----Original Message----- > From: Jiang, Guomin <[email protected]> > Sent: Sunday, March 22, 2020 10:56 PM > To: [email protected]; Zhang, Shenglei > <[email protected]>; [email protected] > Cc: Kinney, Michael D <[email protected]>; > [email protected]; [email protected] > Subject: RE: [edk2-devel] [PATCH] UnitTestFrameworkPkg: > Invalid index may be used. > > Hi Michael, Sean, Bret, > > Could help review the patch? > > Thanks > > -----Original Message----- > > From: [email protected] > [mailto:[email protected]] On Behalf Of > > Zhang, Shenglei > > Sent: Wednesday, March 4, 2020 3:59 PM > > To: [email protected]; [email protected] > > Subject: Re: [edk2-devel] [PATCH] > UnitTestFrameworkPkg: Invalid index may > > be used. > > > > Reviewed-by: Shenglei Zhang > <[email protected]> > > > > > -----Original Message----- > > > From: [email protected] > [mailto:[email protected]] On Behalf Of > > > GuoMinJ > > > Sent: Thursday, February 20, 2020 9:42 AM > > > To: [email protected] > > > Cc: GuoMinJ <[email protected]> > > > Subject: [edk2-devel] [PATCH] UnitTestFrameworkPkg: > Invalid index may > > > be used. > > > > > > REF: > https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbugzilla.tianocore.org%2Fshow_bug.cgi%3Fid%3D2535&data=02%7C01%7CBret.Barkelew%40microsoft.com%7C6e119160718c41dd8bea08d7cf503d05%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637205815839534686&sdata=G5r02YNEXW3PG%2BJUsOg9A5BrKdqpkdlJHceyK4Gkd1Y%3D&reserved=0 > > > > > > The UINT_TEST_STATUS and FAILURE_TYPE have used 0 > as status, so use 0 > > > as unknown is confused, remove it from array > enumeration but keep it > > > location in the array. > > > > > > Signed-off-by: GuoMinJ <[email protected]> > > > --- > > > > .../Library/UnitTestResultReportLib/UnitTestResultRepor > tLib.c | 4 > > > ++-- > > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > > > diff --git > > > > > > a/UnitTestFrameworkPkg/Library/UnitTestResultReportLib/ > UnitTestResultR > > > eportLib.c > > > > > > b/UnitTestFrameworkPkg/Library/UnitTestResultReportLib/ > UnitTestResultR > > > eportLib.c > > > index 687a04f55d..eba68e330c 100644 > > > --- > > > > > > a/UnitTestFrameworkPkg/Library/UnitTestResultReportLib/ > UnitTestResultR > > > eportLib.c > > > +++ > > > > > > b/UnitTestFrameworkPkg/Library/UnitTestResultReportLib/ > UnitTestResultR > > > eportLib.c > > > @@ -65,7 +65,7 @@ GetStringForUnitTestStatus ( { > > > UINTN Index; > > > > > > - for (Index = 0; Index < ARRAY_SIZE > (mStatusStrings); Index++) { > > > + for (Index = 0; Index < ARRAY_SIZE > (mStatusStrings) - 1; Index++) { > > > if (mStatusStrings[Index].Status == Status) { > > > // > > > // Return string from matching entry @@ - > 87,7 +87,7 @@ > > > GetStringForFailureType ( { > > > UINTN Index; > > > > > > - for (Index = 0; Index < ARRAY_SIZE > (mFailureTypeStrings); Index++) > > > { > > > + for (Index = 0; Index < ARRAY_SIZE > (mFailureTypeStrings) - 1; > > > + Index++) { > > > if (mFailureTypeStrings[Index].Type == > Failure) { > > > // > > > // Return string from matching entry > > > -- > > > 2.17.1 > > > > > > > > > > > > > > > -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#56168): https://edk2.groups.io/g/devel/message/56168 Mute This Topic: https://groups.io/mt/71411719/21656 Group Owner: [email protected] Unsubscribe: https://edk2.groups.io/g/devel/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
