diff options
Diffstat (limited to 'src/arch')
-rw-r--r-- | src/arch/x86/processor.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/arch/x86/processor.c b/src/arch/x86/processor.c index 5694d9e..14f35bc 100644 --- a/src/arch/x86/processor.c +++ b/src/arch/x86/processor.c @@ -446,8 +446,18 @@ void x86_print_instruction(const asm_x86_processor *proc, const exe_format *form { oplen = strlen(opbuffer[i]); - if (offset == 0) snprintf(&opbuffer[i][oplen], 256 - oplen, " <%s>", label); - else snprintf(&opbuffer[i][oplen], 256 - oplen, " <%s+0x%llx>", label, offset); + switch (symtype) + { + case STP_SECTION: + if (offset == 0) snprintf(&opbuffer[i][oplen], 256 - oplen, " <%s>", label); + else snprintf(&opbuffer[i][oplen], 256 - oplen, " <%s+0x%llx>", label, offset); + break; + + case STP_STRING: + snprintf(&opbuffer[i][oplen], 256 - oplen, " \"%s\"", label); + break; + + } free(label); |