diff --git a/dlls/d3dx9_36/xfile.c b/dlls/d3dx9_36/xfile.c index 157545482bf..649ea9672da 100644 --- a/dlls/d3dx9_36/xfile.c +++ b/dlls/d3dx9_36/xfile.c @@ -588,7 +588,7 @@ static HRESULT WINAPI d3dx9_file_CreateEnumObject(ID3DXFile *iface, const void * { D3DXF_FILELOADMEMORY *memory = (D3DXF_FILELOADMEMORY*)source; - dxfile_memory.lpMemory = memory->lpMemory; + dxfile_memory.lpMemory = (void *)memory->lpMemory; dxfile_memory.dSize = memory->dSize; dxfile_source = &dxfile_memory; dxfile_options = DXFILELOAD_FROMMEMORY; diff --git a/include/d3dx9xof.h b/include/d3dx9xof.h index 35019f26d4e..227f3a57ba2 100644 --- a/include/d3dx9xof.h +++ b/include/d3dx9xof.h @@ -49,7 +49,7 @@ typedef struct _D3DXF_FILELOADRESOURCE typedef struct _D3DXF_FILELOADMEMORY { - void *lpMemory; + const void *lpMemory; SIZE_T dSize; } D3DXF_FILELOADMEMORY;