fix disassembly of 20-bit calla operands

This commit is contained in:
Peter A. Bigot 2012-06-02 09:34:04 -05:00 committed by Daniel Beer
parent 8fe14ca1da
commit 25f6df0d0f
2 changed files with 3 additions and 2 deletions

View File

@ -212,6 +212,7 @@ static int decode_13xx(const uint8_t *code, address_t len,
if (len < 4)
return -1;
insn->dsize = MSP430_DSIZE_AWORD;
insn->dst_addr |= code[2];
insn->dst_addr |= code[3] << 8;

View File

@ -24,7 +24,7 @@
#include "stab.h"
#include "util.h"
static int format_addr(msp430_amode_t amode, uint16_t addr)
static int format_addr(msp430_amode_t amode, address_t addr)
{
char name[64];
const char *prefix = "";
@ -91,7 +91,7 @@ static int format_reg(msp430_amode_t amode, msp430_reg_t reg)
*
* Returns the number of characters printed.
*/
static int format_operand(msp430_amode_t amode, uint16_t addr,
static int format_operand(msp430_amode_t amode, address_t addr,
msp430_reg_t reg)
{
int len = 0;