mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-08-02 12:08:11 +00:00
fix signedness issue
This commit is contained in:
committed by
Ryan Fleury
parent
671431cfbd
commit
a3bcfe01e1
+4
-4
@@ -178,7 +178,7 @@ coff_pick_reloc_value_x64(COFF_Reloc_X64 type,
|
||||
U64 reloc_virtual_offset,
|
||||
U32 symbol_section_number,
|
||||
U32 symbol_section_offset,
|
||||
U32 symbol_virtual_offset)
|
||||
S64 symbol_virtual_offset)
|
||||
{
|
||||
U64 reloc_value_size = 0;
|
||||
S64 reloc_value = 0;
|
||||
@@ -187,15 +187,15 @@ coff_pick_reloc_value_x64(COFF_Reloc_X64 type,
|
||||
case COFF_Reloc_X64_Abs: {} break;
|
||||
case COFF_Reloc_X64_Addr64: {
|
||||
reloc_value_size = 8;
|
||||
reloc_value = symbol_virtual_offset + image_base;
|
||||
reloc_value = symbol_virtual_offset + (S64)image_base;
|
||||
} break;
|
||||
case COFF_Reloc_X64_Addr32: {
|
||||
reloc_value_size = 4;
|
||||
reloc_value = symbol_virtual_offset + image_base;
|
||||
reloc_value = safe_cast_s32(symbol_virtual_offset + (S64)image_base);
|
||||
} break;
|
||||
case COFF_Reloc_X64_Addr32Nb: {
|
||||
reloc_value_size = 4;
|
||||
reloc_value = safe_cast_u32(symbol_virtual_offset);
|
||||
reloc_value = symbol_virtual_offset;
|
||||
} break;
|
||||
case COFF_Reloc_X64_Rel32: {
|
||||
reloc_value_size = 4;
|
||||
|
||||
+1
-1
@@ -601,7 +601,7 @@ internal String8 coff_read_symbol_name(String8 string_table, COFF_SymbolName *na
|
||||
internal U64 coff_apply_size_from_reloc_x64(COFF_Reloc_X64 x);
|
||||
internal U64 coff_apply_size_from_reloc_x86(COFF_Reloc_X86 x);
|
||||
|
||||
internal COFF_RelocValue coff_pick_reloc_value_x64(COFF_Reloc_X64 type, U64 image_base, U64 reloc_virtual_offset, U32 symbol_section_number, U32 symbol_section_offset, U32 symbol_virtual_offset);
|
||||
internal COFF_RelocValue coff_pick_reloc_value_x64(COFF_Reloc_X64 type, U64 image_base, U64 reloc_virtual_offset, U32 symbol_section_number, U32 symbol_section_offset, S64 symbol_virtual_offset);
|
||||
|
||||
////////////////////////////////
|
||||
// Import
|
||||
|
||||
Reference in New Issue
Block a user