// Allocate a buffer to hold the DHCP options, and after that, a\r
// continuous buffer to put all the options' data.\r
//\r
- Options = AllocateZeroPool (OptNum * sizeof (DHCP_OPTION) + TotalLen);\r
+ Options = AllocateZeroPool ((UINTN) (OptNum * sizeof (DHCP_OPTION)) + TotalLen);\r
\r
if (Options == NULL) {\r
Status = EFI_OUT_OF_RESOURCES;\r
\r
*(Buf++) = Tag;\r
*(Buf++) = (UINT8) Len;\r
- CopyMem (Buf, Data + Index * 255, Len);\r
+ CopyMem (Buf, Data + Index * 255, (UINTN) Len);\r
\r
Buf += Len;\r
}\r