Skip to content

Commit

Permalink
disasm: Fix address type in print function
Browse files Browse the repository at this point in the history
  • Loading branch information
mefistotelis committed Jan 8, 2024
1 parent 55857da commit 13ea98c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/disassembler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ Disassembler::receive_instruction_styled_text (void *context,
}

void
Disassembler::print_address (unsigned long address, disassemble_info *info)
Disassembler::print_address (bfd_vma address, disassemble_info *info)
{
info->fprintf_func (info->stream, "0x%lx", address);
info->fprintf_func (info->stream, "0x%llx", (unsigned long long)address);
}
2 changes: 1 addition & 1 deletion src/disassembler.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class Disassembler
static int receive_instruction_text (void *context, const char *fmt, ...);
static int receive_instruction_styled_text (void *context,
enum disassembler_style style, const char *fmt, ...);
static void print_address (unsigned long address, disassemble_info *info);
static void print_address (bfd_vma address, disassemble_info *info);

public:
Disassembler (void);
Expand Down

0 comments on commit 13ea98c

Please sign in to comment.