]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Universal/DevicePathDxe/DevicePathToText.c
Add some ASSERT()s.
[mirror_edk2.git] / MdeModulePkg / Universal / DevicePathDxe / DevicePathToText.c
index 2e4a976adc397aa93a05dd55bb965b7d92306383..d45c267ffbbcfe5c9387c0444bc5820e66032d85 100644 (file)
@@ -708,6 +708,7 @@ DevPathToTextUsbWWID (
     // In case no NULL terminator in SerialNumber, create a new one with NULL terminator\r
     //\r
     NewStr = AllocateCopyPool ((Length + 1) * sizeof (CHAR16), SerialNumberStr);\r
+    ASSERT (NewStr != NULL);\r
     NewStr [Length] = 0;\r
     SerialNumberStr = NewStr;\r
   }\r