Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-20 Thread Sean
; Laszlo Ersek ; Leif Lindholm ; Gao, Liming ; Marvin H?user ; Zimmer, Vincent ; Gao, Zhichao ; Yao, Jiewen ; Vitaly Cheptsov Subject: Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test Mike, I would have thought the SafeString tests would have gone

Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-20 Thread Michael D Kinney
Hi Vitaly, I agree with all the comments here. I have made these updates in V9. Mike From: vit9696 Sent: Tuesday, May 19, 2020 11:08 PM To: Kinney, Michael D Cc: devel@edk2.groups.io; Andrew Fish ; Ard Biesheuvel ; Bret Barkelew ; Brian J . Johnson ; Chiu, Chasel ; Justen, Jordan L ;

Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-20 Thread Michael D Kinney
t; ; Zimmer, Vincent > ; Gao, Zhichao > ; Yao, Jiewen > ; Vitaly Cheptsov > > Subject: Re: [edk2-devel] [Patch v8 2/2] > MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK > unit test > > Mike, > > I would have thought the SafeString tests would have > go

Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-20 Thread Sean
Mike, I would have thought the SafeString tests would have gone in a different c file. Base64UnitTest.c seems by its title to be targeted at the base64 encode/decode test. Looking at this i do see that would require some restructuring as there is no BaseLibUnitTest.c file for the common

Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-20 Thread Laszlo Ersek
On 05/20/20 05:11, Michael D Kinney wrote: > Use the safe string function StrCpyS() in BaseLib to test the > SAFE_STRING_CONSTRAINT_CHECK() macro. > > Cc: Andrew Fish > Cc: Ard Biesheuvel > Cc: Bret Barkelew > Cc: Brian J. Johnson > Cc: Chasel Chiu > Cc: Jordan Justen > Cc: Laszlo Ersek >

Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-20 Thread Philippe Mathieu-Daudé
On 5/20/20 8:07 AM, Vitaly Cheptsov via groups.io wrote: Mike, This looks generally good to me, but there are few issues. 1. There is a mistake in the description here: +  // Negative test case with DestMax smaller than Source size +  // +  Status = StrCpyS (Destination, sizeof (Destination)

Re: [edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-20 Thread Vitaly Cheptsov via groups.io
Mike, This looks generally good to me, but there are few issues. 1. There is a mistake in the description here: + // Negative test case with DestMax smaller than Source size + // + Status = StrCpyS (Destination, sizeof (Destination) / sizeof (CHAR16), Destination); This should read

[edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-19 Thread Michael D Kinney
Use the safe string function StrCpyS() in BaseLib to test the SAFE_STRING_CONSTRAINT_CHECK() macro. Cc: Andrew Fish Cc: Ard Biesheuvel Cc: Bret Barkelew Cc: Brian J. Johnson Cc: Chasel Chiu Cc: Jordan Justen Cc: Laszlo Ersek Cc: Leif Lindholm Cc: Liming Gao Cc: Marvin H?user Cc: Michael

[edk2-devel] [Patch v8 2/2] MdePkg/Test/BaseLib: Add SAFE_STRING_CONSTRAINT_CHECK unit test

2020-05-19 Thread Michael D Kinney
Use the safe string function StrCpyS() in BaseLib to test the SAFE_STRING_CONSTRAINT_CHECK() macro. Cc: Andrew Fish Cc: Ard Biesheuvel Cc: Bret Barkelew Cc: Brian J. Johnson Cc: Chasel Chiu Cc: Jordan Justen Cc: Laszlo Ersek Cc: Leif Lindholm Cc: Liming Gao Cc: Marvin H?user Cc: Michael