summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--MdeModulePkg/Core/Pei/FwVol/FwVol.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/MdeModulePkg/Core/Pei/FwVol/FwVol.c b/MdeModulePkg/Core/Pei/FwVol/FwVol.c
index 7b74edb..7af6748 100644
--- a/MdeModulePkg/Core/Pei/FwVol/FwVol.c
+++ b/MdeModulePkg/Core/Pei/FwVol/FwVol.c
@@ -642,6 +642,10 @@ PeiFfsFindNextVolume (
PEI_CORE_INSTANCE *Private;
PEI_CORE_FV_HANDLE *CoreFvHandle;
+ if (VolumeHandle == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
Private = PEI_CORE_INSTANCE_FROM_PS_THIS (PeiServices);
CoreFvHandle = FindNextCoreFvHandle (Private, Instance);