]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/C/DevicePath/DevicePathUtilities.c
BaseTools/DevicePath: use MAX_UINT32 as default device path max size
[mirror_edk2.git] / BaseTools / Source / C / DevicePath / DevicePathUtilities.c
index d4ec2742b7c873ebd6d00c3e2a28d1c1bf64e043..f8a41ff97dd8cf284d30f85d2a002ef05772fc4c 100644 (file)
@@ -62,7 +62,7 @@ IsDevicePathValid (
   ASSERT (DevicePath != NULL);\r
 \r
   if (MaxSize == 0) {\r
-    MaxSize = MAX_UINTN;\r
+    MaxSize = MAX_UINT32;\r
  }\r
 \r
   //\r
@@ -78,7 +78,7 @@ IsDevicePathValid (
       return FALSE;\r
     }\r
 \r
-    if (NodeLength > MAX_UINTN - Size) {\r
+    if (NodeLength > MAX_UINT32 - Size) {\r
       return FALSE;\r
     }\r
     Size += NodeLength;\r