From: lzeng14 Date: Fri, 3 Feb 2012 07:48:57 +0000 (+0000) Subject: Append double-null for Type 19 data record. X-Git-Tag: edk2-stable201903~13661 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=3e570e6e52bc5c2ea0fbe479c2a49107c754788c;p=mirror_edk2.git Append double-null for Type 19 data record. Signed-off-by: lzeng14 Reviewed-by: li-elvin git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12983 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/EmulatorPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c b/EmulatorPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c index fc2275cc7a..65fec01158 100644 --- a/EmulatorPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c +++ b/EmulatorPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c @@ -1,6 +1,6 @@ /*++ -Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.
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 @@ -77,8 +77,7 @@ LogMemorySmbiosRecord ( // // Generate Memory Array Mapped Address info // - Type19Record = AllocatePool(sizeof (SMBIOS_TABLE_TYPE19)); - ZeroMem(Type19Record, sizeof(SMBIOS_TABLE_TYPE19)); + Type19Record = AllocateZeroPool(sizeof (SMBIOS_TABLE_TYPE19) + 2); Type19Record->Hdr.Type = EFI_SMBIOS_TYPE_MEMORY_ARRAY_MAPPED_ADDRESS; Type19Record->Hdr.Length = sizeof(SMBIOS_TABLE_TYPE19); Type19Record->Hdr.Handle = 0; diff --git a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c index 95e050f323..7e58ef5230 100644 --- a/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c +++ b/Nt32Pkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c @@ -1,6 +1,6 @@ /**@file -Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.
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 @@ -77,8 +77,7 @@ LogMemorySmbiosRecord ( // // Generate Memory Array Mapped Address info // - Type19Record = AllocatePool(sizeof (SMBIOS_TABLE_TYPE19)); - ZeroMem(Type19Record, sizeof(SMBIOS_TABLE_TYPE19)); + Type19Record = AllocateZeroPool(sizeof (SMBIOS_TABLE_TYPE19) + 2); Type19Record->Hdr.Type = EFI_SMBIOS_TYPE_MEMORY_ARRAY_MAPPED_ADDRESS; Type19Record->Hdr.Length = sizeof(SMBIOS_TABLE_TYPE19); Type19Record->Hdr.Handle = 0; diff --git a/UnixPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c b/UnixPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c index 41b32fe673..283a76139c 100644 --- a/UnixPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c +++ b/UnixPkg/MiscSubClassPlatformDxe/MiscSubclassDriverEntryPoint.c @@ -1,6 +1,6 @@ /*++ -Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.
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 @@ -77,8 +77,7 @@ LogMemorySmbiosRecord ( // // Generate Memory Array Mapped Address info // - Type19Record = AllocatePool(sizeof (SMBIOS_TABLE_TYPE19)); - ZeroMem(Type19Record, sizeof(SMBIOS_TABLE_TYPE19)); + Type19Record = AllocateZeroPool(sizeof (SMBIOS_TABLE_TYPE19) + 2); Type19Record->Hdr.Type = EFI_SMBIOS_TYPE_MEMORY_ARRAY_MAPPED_ADDRESS; Type19Record->Hdr.Length = sizeof(SMBIOS_TABLE_TYPE19); Type19Record->Hdr.Handle = 0;