Skip to content

Commit bb736dc

Browse files
committed
Added explicit casts.
1 parent da78edc commit bb736dc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

MemoryModule.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,7 @@ HMEMORYMODULE MemoryLoadLibraryEx(const void *data,
420420
result->headers->OptionalHeader.ImageBase = (POINTER_TYPE)code;
421421

422422
// copy sections from DLL file block to new memory location
423-
CopySections(data, old_header, result);
423+
CopySections((const unsigned char *) data, old_header, result);
424424

425425
// adjust base address of imported data
426426
locationDelta = (SIZE_T)(code - old_header->OptionalHeader.ImageBase);
@@ -728,7 +728,7 @@ MemoryLoadStringEx(HMEMORYMODULE module, UINT id, LPTSTR buffer, int maxsize, WO
728728
return 0;
729729
}
730730

731-
data = MemoryLoadResource(module, resource);
731+
data = (PIMAGE_RESOURCE_DIR_STRING_U) MemoryLoadResource(module, resource);
732732
id = id & 0x0f;
733733
while (id--) {
734734
data = (PIMAGE_RESOURCE_DIR_STRING_U) (((char *) data) + (data->Length + 1) * sizeof(WCHAR));

0 commit comments

Comments
 (0)