summaryrefslogtreecommitdiff
path: root/StandaloneMmPkg
diff options
context:
space:
mode:
authorZhiguang Liu <zhiguang.liu@intel.com>2024-04-24 15:27:20 +0800
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2024-05-30 01:57:35 +0000
commit30b6d08e27c767ba9756a244099d73c826abcc8d (patch)
tree40b9cf70da354aee1c06f7b086b244f4e22e39d9 /StandaloneMmPkg
parentb40c64ec25986d36e1fd02304daa9d72ac863da6 (diff)
downloadedk2-30b6d08e27c767ba9756a244099d73c826abcc8d.zip
edk2-30b6d08e27c767ba9756a244099d73c826abcc8d.tar.gz
edk2-30b6d08e27c767ba9756a244099d73c826abcc8d.tar.bz2
StandaloneMmPkg: Initialize 'WillReturn' variable
The local variable 'WillReturn' was being used without prior initialization in some code paths. This patch ensures that 'WillReturn' is properly initialized to prevent undefined behavior. Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
Diffstat (limited to 'StandaloneMmPkg')
-rw-r--r--StandaloneMmPkg/Core/Mmi.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/StandaloneMmPkg/Core/Mmi.c b/StandaloneMmPkg/Core/Mmi.c
index e035245..fb205df 100644
--- a/StandaloneMmPkg/Core/Mmi.c
+++ b/StandaloneMmPkg/Core/Mmi.c
@@ -174,6 +174,7 @@ MmiManage (
EFI_STATUS Status;
mMmiManageCallingDepth++;
+ WillReturn = FALSE;
Status = EFI_NOT_FOUND;
ReturnStatus = Status;
if (HandlerType == NULL) {