]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrForm.c
enhanced security check.
[mirror_edk2.git] / MdeModulePkg / Library / UefiIfrSupportLib / UefiIfrForm.c
index 1584c33d92a661fa88eda3768a0b1380106599fa..a81423763b0dd412ac24f4c1af127bac6ed78cfa 100644 (file)
@@ -973,6 +973,11 @@ ConstructConfigHdr (
   CHAR16                    *StrPtr;\r
   EFI_DEVICE_PATH_PROTOCOL  *DevicePath;\r
 \r
+  //\r
+  // Make sure \r
+  //\r
+  ASSERT (!(ConfigHdr == NULL && *StrBufferLen != 0));\r
+\r
   if (Name == NULL) {\r
     //\r
     // There will be no "NAME" in <ConfigHdr> for  Name/Value storage\r