[edk2-devel] [PATCH v1 2/2] SecurityPkg: OpalPasswordDxe: uninitialized local variable.
Paul via groups.io
paul.grimes=amd.com at groups.io
Sat Oct 22 16:00:10 UTC 2022
From: Paul Grimes <paul.grimes at amd.com>
In ProcessOpalRequest(), VariableSize is used prior to being
initialized. This change initializes the variable.
Cc: Qi Zhang <qi1.zhang at intel.com>
Cc: Rahul Kumar <rahul1.kumar at intel.com>
Signed-off-by: Paul Grimes <paul.grimes at amd.com>
---
SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c b/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c
index f127757ad9f0..d827cea23868 100644
--- a/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c
+++ b/SecurityPkg/Tcg/Opal/OpalPassword/OpalDriver.c
@@ -2184,6 +2184,7 @@ ProcessOpalRequest (
DEBUG ((DEBUG_INFO, "%a() - enter\n", __FUNCTION__));
+ VariableSize = 0;
if (mOpalRequestVariable == NULL) {
Status = GetVariable2 (
OPAL_REQUEST_VARIABLE_NAME,
--
2.24.0.windows.2
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#95483): https://edk2.groups.io/g/devel/message/95483
Mute This Topic: https://groups.io/mt/94499443/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-
More information about the edk2-devel-archive
mailing list