diff --git a/reactos/dll/win32/dbghelp/dwarf.c b/reactos/dll/win32/dbghelp/dwarf.c index 2e007826f0c..a64cba64446 100644 --- a/reactos/dll/win32/dbghelp/dwarf.c +++ b/reactos/dll/win32/dbghelp/dwarf.c @@ -2381,7 +2381,17 @@ static BOOL dwarf2_parse_compilation_unit(const dwarf2_section_t* sections, } if (dwarf2_find_attribute(&ctx, di, DW_AT_stmt_list, &stmt_list)) { +#ifdef __REACTOS__ + unsigned long stmt_list_val = stmt_list.u.uvalue; + if (stmt_list_val > module->module.BaseOfImage) + { + /* FIXME: Clang is recording this as an address, not an offset */ + stmt_list_val -= module->module.BaseOfImage + sections[section_line].rva; + } + if (dwarf2_parse_line_numbers(sections, &ctx, comp_dir.u.string, stmt_list_val)) +#else if (dwarf2_parse_line_numbers(sections, &ctx, comp_dir.u.string, stmt_list.u.uvalue)) +#endif module->module.LineNumbers = TRUE; } ret = TRUE;