public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* Re: [edk2-devel] [PATCH] UnitTestFrameworkPkg/PersistenceLib: Correct the allocated size.
       [not found] <160144926718B366.16021@groups.io>
@ 2020-04-08  5:27 ` Guomin Jiang
  2020-04-08  6:02   ` Sean
  0 siblings, 1 reply; 2+ messages in thread
From: Guomin Jiang @ 2020-04-08  5:27 UTC (permalink / raw)
  To: devel@edk2.groups.io, Jiang, Guomin
  Cc: Kinney, Michael D, Sean Brogan, Bret Barkelew

Hi Kinney, Sean, Bret,

Could you help review the change?

Best Regards
Guomin

> -----Original Message-----
> From: devel@edk2.groups.io <devel@edk2.groups.io> On Behalf Of Guomin
> Jiang
> Sent: Tuesday, March 31, 2020 11:06 AM
> To: devel@edk2.groups.io
> Cc: Kinney, Michael D <michael.d.kinney@intel.com>; Sean Brogan
> <sean.brogan@microsoft.com>; Bret Barkelew
> <Bret.Barkelew@microsoft.com>
> Subject: [edk2-devel] [PATCH] UnitTestFrameworkPkg/PersistenceLib:
> Correct the allocated size.
> 
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2608
> 
> According to logic and the practice, it is need to allocate ascii length
> by 2 for unicode string.
> 
> Cc: Michael D Kinney <michael.d.kinney@intel.com>
> Cc: Sean Brogan <sean.brogan@microsoft.com>
> Cc: Bret Barkelew <Bret.Barkelew@microsoft.com>
> Signed-off-by: Guomin Jiang <guomin.jiang@intel.com>
> ---
>  .../UnitTestPersistenceLibSimpleFileSystem.c                    | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git
> a/UnitTestFrameworkPkg/Library/UnitTestPersistenceLibSimpleFileSystem/
> UnitTestPersistenceLibSimpleFileSystem.c
> b/UnitTestFrameworkPkg/Library/UnitTestPersistenceLibSimpleFileSystem/
> UnitTestPersistenceLibSimpleFileSystem.c
> index ccca9bfacb..6da85c459d 100644
> ---
> a/UnitTestFrameworkPkg/Library/UnitTestPersistenceLibSimpleFileSystem/
> UnitTestPersistenceLibSimpleFileSystem.c
> +++
> b/UnitTestFrameworkPkg/Library/UnitTestPersistenceLibSimpleFileSystem/
> UnitTestPersistenceLibSimpleFileSystem.c
> @@ -67,7 +67,7 @@ GetCacheFileDevicePath (
>    // Before we can start, change test name from ASCII to Unicode.
> 
>    //
> 
>    CacheFilePathLength = AsciiStrLen (Framework->ShortTitle) + 1;
> 
> -  TestName = AllocatePool (CacheFilePathLength);
> 
> +  TestName = AllocatePool (CacheFilePathLength * sizeof(CHAR16));
> 
>    if (!TestName) {
> 
>      goto Exit;
> 
>    }
> 
> --
> 2.25.1.windows.1
> 
> 
> -=-=-=-=-=-=
> Groups.io Links: You receive all messages sent to this group.
> 
> View/Reply Online (#56714): https://edk2.groups.io/g/devel/message/56714
> Mute This Topic: https://groups.io/mt/72670002/4399222
> Group Owner: devel+owner@edk2.groups.io
> Unsubscribe: https://edk2.groups.io/g/devel/unsub
> [guomin.jiang@intel.com]
> -=-=-=-=-=-=


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [edk2-devel] [PATCH] UnitTestFrameworkPkg/PersistenceLib: Correct the allocated size.
  2020-04-08  5:27 ` [edk2-devel] [PATCH] UnitTestFrameworkPkg/PersistenceLib: Correct the allocated size Guomin Jiang
@ 2020-04-08  6:02   ` Sean
  0 siblings, 0 replies; 2+ messages in thread
From: Sean @ 2020-04-08  6:02 UTC (permalink / raw)
  To: Guomin Jiang, devel

[-- Attachment #1: Type: text/plain, Size: 54 bytes --]

Reviewed-by: Sean Brogan <sean.brogan@microsoft.com>

[-- Attachment #2: Type: text/html, Size: 314 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-04-08  6:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <160144926718B366.16021@groups.io>
2020-04-08  5:27 ` [edk2-devel] [PATCH] UnitTestFrameworkPkg/PersistenceLib: Correct the allocated size Guomin Jiang
2020-04-08  6:02   ` Sean

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox