fix pxw endian issue

This commit is contained in:
Álvaro Felipe Melchor 2016-05-16 23:05:06 +02:00
parent 5d6c3ac947
commit f6a0cfbcb9
2 changed files with 2 additions and 3 deletions

View File

@ -3150,8 +3150,7 @@ static int cmd_print(void *data, const char *input) {
}
break;
case 'w': // "pxw
r_print_hexdump (core->print, core->offset, core->block,
len, 32, 4);
r_print_hexdump (core->print, core->offset, core->block, len, 32, 4);
break;
case 'W': // "pxW"
len = len - (len%4);

View File

@ -758,7 +758,7 @@ R_API void r_print_hexdump(RPrint *p, ut64 addr, const ut8 *buf, int len, int ba
sz_n = step == 2 ? sizeof (ut16) : sizeof (ut32);
}
sz_n = R_MIN (left, sz_n);
memcpy ((ut8*)&n, buf+j, sz_n);
r_mem_swaporcopy ((ut8*)&n, buf+j, sz_n, p->big_endian);
r_print_cursor (p, j, 1);
// stub for colors
if (p && p->colorfor) {