mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-26 15:14:02 +02:00
SecurityPkg: TcgStorageOpalLib: Initialize SupportedAttributes parameter.
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3408 The value of SupportedAttributes in OpalGetSupportedAttributesInfo () is left undetermined, if the caller doesn't initialize it. Initialize it in the function entry. Signed-off-by: Scottie Kuo <scottie.kuo@intel.com> Cc: Qi Zhang <qi1.zhang@intel.com> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Maggie Chu <maggie.chu@intel.com> Reviewed-by: Jiewen Yao <Jiewen.yao@intel.com> Acked-by: Jian J Wang <jian.j.wang@intel.com>
This commit is contained in:
parent
1ad794b627
commit
11b1c1d4b9
@ -1,7 +1,7 @@
|
|||||||
/** @file
|
/** @file
|
||||||
Public API for Opal Core library.
|
Public API for Opal Core library.
|
||||||
|
|
||||||
Copyright (c) 2016 - 2018, Intel Corporation. All rights reserved.<BR>
|
Copyright (c) 2016 - 2021, Intel Corporation. All rights reserved.<BR>
|
||||||
SPDX-License-Identifier: BSD-2-Clause-Patent
|
SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||||
|
|
||||||
**/
|
**/
|
||||||
@ -1647,6 +1647,7 @@ OpalGetSupportedAttributesInfo(
|
|||||||
NULL_CHECK(OpalBaseComId);
|
NULL_CHECK(OpalBaseComId);
|
||||||
|
|
||||||
ZeroMem(Buffer, BUFFER_SIZE);
|
ZeroMem(Buffer, BUFFER_SIZE);
|
||||||
|
ZeroMem(SupportedAttributes, sizeof(OPAL_DISK_SUPPORT_ATTRIBUTE));
|
||||||
ASSERT(sizeof(Buffer) >= sizeof(TCG_SUPPORTED_SECURITY_PROTOCOLS));
|
ASSERT(sizeof(Buffer) >= sizeof(TCG_SUPPORTED_SECURITY_PROTOCOLS));
|
||||||
|
|
||||||
//
|
//
|
||||||
|
Loading…
x
Reference in New Issue
Block a user