Eric Pouech : dbghelp: Ensure all adresses are stored at least in DWORD_PTR.
Alexandre Julliard
julliard at winehq.org
Fri Sep 10 15:29:45 CDT 2021
Module: wine
Branch: master
Commit: f4afcb3f5a99e3090c3aa1f00ce0903f6e8c48a9
URL: https://source.winehq.org/git/wine.git/?a=commit;h=f4afcb3f5a99e3090c3aa1f00ce0903f6e8c48a9
Author: Eric Pouech <eric.pouech at gmail.com>
Date: Fri Sep 10 15:52:09 2021 +0200
dbghelp: Ensure all adresses are stored at least in DWORD_PTR.
Signed-off-by: Eric Pouech <eric.pouech at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/dbghelp/cpu_arm64.c | 2 +-
dlls/dbghelp/pe_module.c | 6 +++---
dlls/dbghelp/symbol.c | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/dlls/dbghelp/cpu_arm64.c b/dlls/dbghelp/cpu_arm64.c
index 515294fe95c..2c767e78de4 100644
--- a/dlls/dbghelp/cpu_arm64.c
+++ b/dlls/dbghelp/cpu_arm64.c
@@ -264,7 +264,7 @@ static BOOL arm64_fetch_minidump_thread(struct dump_context* dc, unsigned index,
{
/* FIXME: crop values across module boundaries, */
#ifdef __aarch64__
- ULONG base = ctx->Pc <= 0x80 ? 0 : ctx->Pc - 0x80;
+ ULONG64 base = ctx->Pc <= 0x80 ? 0 : ctx->Pc - 0x80;
minidump_add_memory_block(dc, base, ctx->Pc + 0x80 - base, 0);
#endif
}
diff --git a/dlls/dbghelp/pe_module.c b/dlls/dbghelp/pe_module.c
index 38829d6e6de..278f3c71c98 100644
--- a/dlls/dbghelp/pe_module.c
+++ b/dlls/dbghelp/pe_module.c
@@ -652,7 +652,7 @@ static BOOL pe_load_export_debug_info(const struct process* pcs, struct module*
struct image_file_map* fmap = &module->format_info[DFI_PE]->u.pe_info->fmap;
unsigned int i;
const IMAGE_EXPORT_DIRECTORY* exports;
- DWORD base = module->module.BaseOfImage;
+ DWORD_PTR base = module->module.BaseOfImage;
DWORD size;
IMAGE_NT_HEADERS* nth;
void* mapping;
@@ -716,7 +716,7 @@ static BOOL pe_load_export_debug_info(const struct process* pcs, struct module*
if ((ordinals[j] == i) && names[j]) break;
if (j < exports->NumberOfNames) continue;
snprintf(buffer, sizeof(buffer), "%d", i + exports->Base);
- symt_new_public(module, NULL, buffer, FALSE, base + (DWORD)functions[i], 1);
+ symt_new_public(module, NULL, buffer, FALSE, base + functions[i], 1);
}
}
}
@@ -906,7 +906,7 @@ struct module* pe_load_builtin_module(struct process* pcs, const WCHAR* name,
PVOID WINAPI ImageDirectoryEntryToDataEx( PVOID base, BOOLEAN image, USHORT dir, PULONG size, PIMAGE_SECTION_HEADER *section )
{
const IMAGE_NT_HEADERS *nt;
- DWORD addr;
+ DWORD_PTR addr;
*size = 0;
if (section) *section = NULL;
diff --git a/dlls/dbghelp/symbol.c b/dlls/dbghelp/symbol.c
index 28c906c10a3..3b44315eebd 100644
--- a/dlls/dbghelp/symbol.c
+++ b/dlls/dbghelp/symbol.c
@@ -929,7 +929,7 @@ static BOOL symt_enum_locals_helper(struct module_pair* pair,
struct symt_function* func, const struct vector* v)
{
struct symt* lsym = NULL;
- DWORD pc = pair->pcs->ctx_frame.InstructionOffset;
+ DWORD_PTR pc = pair->pcs->ctx_frame.InstructionOffset;
unsigned int i;
WCHAR* nameW;
BOOL ret;
More information about the wine-cvs
mailing list