From 6096e5861ae8ab99dcbb86a78cb612f9fea2e093 Mon Sep 17 00:00:00 2001 From: Ge van Geldorp Date: Mon, 10 Jul 2006 08:58:12 +0200 Subject: [PATCH] ntdll: Widen fields in LDR_RESOURCE_INFO to accomodate 64 bit pointers. --- dlls/kernel/resource.c | 16 ++++++++-------- include/winternl.h | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/dlls/kernel/resource.c b/dlls/kernel/resource.c index 3d95696a7e..aed006a5cd 100644 --- a/dlls/kernel/resource.c +++ b/dlls/kernel/resource.c @@ -137,8 +137,8 @@ static HRSRC find_resourceA( HMODULE hModule, LPCSTR type, LPCSTR name, WORD lan { if ((status = get_res_nameA( name, &nameW )) != STATUS_SUCCESS) goto done; if ((status = get_res_nameA( type, &typeW )) != STATUS_SUCCESS) goto done; - info.Type = (ULONG)typeW.Buffer; - info.Name = (ULONG)nameW.Buffer; + info.Type = (ULONG_PTR)typeW.Buffer; + info.Name = (ULONG_PTR)nameW.Buffer; info.Language = lang; status = LdrFindResource_U( hModule, &info, 3, &entry ); done: @@ -170,8 +170,8 @@ static HRSRC find_resourceW( HMODULE hModule, LPCWSTR type, LPCWSTR name, WORD l { if ((status = get_res_nameW( name, &nameW )) != STATUS_SUCCESS) goto done; if ((status = get_res_nameW( type, &typeW )) != STATUS_SUCCESS) goto done; - info.Type = (ULONG)typeW.Buffer; - info.Name = (ULONG)nameW.Buffer; + info.Type = (ULONG_PTR)typeW.Buffer; + info.Name = (ULONG_PTR)nameW.Buffer; info.Language = lang; status = LdrFindResource_U( hModule, &info, 3, &entry ); done: @@ -495,8 +495,8 @@ BOOL WINAPI EnumResourceLanguagesA( HMODULE hmod, LPCSTR type, LPCSTR name, goto done; if ((status = get_res_nameA( name, &nameW )) != STATUS_SUCCESS) goto done; - info.Type = (ULONG)typeW.Buffer; - info.Name = (ULONG)nameW.Buffer; + info.Type = (ULONG_PTR)typeW.Buffer; + info.Name = (ULONG_PTR)nameW.Buffer; if ((status = LdrFindResourceDirectory_U( hmod, &info, 2, &resdir )) != STATUS_SUCCESS) goto done; @@ -538,8 +538,8 @@ BOOL WINAPI EnumResourceLanguagesW( HMODULE hmod, LPCWSTR type, LPCWSTR name, goto done; if ((status = get_res_nameW( name, &nameW )) != STATUS_SUCCESS) goto done; - info.Type = (ULONG)typeW.Buffer; - info.Name = (ULONG)nameW.Buffer; + info.Type = (ULONG_PTR)typeW.Buffer; + info.Name = (ULONG_PTR)nameW.Buffer; if ((status = LdrFindResourceDirectory_U( hmod, &info, 2, &resdir )) != STATUS_SUCCESS) goto done; diff --git a/include/winternl.h b/include/winternl.h index 2f85171dff..51773484fc 100644 --- a/include/winternl.h +++ b/include/winternl.h @@ -1245,8 +1245,8 @@ typedef BOOLEAN (WINAPI * PWINSTATIONQUERYINFORMATIONW)(HANDLE,ULONG,WINSTATIONI typedef struct _LDR_RESOURCE_INFO { - ULONG Type; - ULONG Name; + ULONG_PTR Type; + ULONG_PTR Name; ULONG Language; } LDR_RESOURCE_INFO, *PLDR_RESOURCE_INFO;