mirror of
https://github.com/radareorg/radare2.git
synced 2024-11-28 15:41:38 +00:00
Fixed illegal access on libps (#9192)
This commit is contained in:
parent
e416a79097
commit
9a63f43d01
@ -107,7 +107,7 @@ bool libps_decode(ut32 data, ppcps_t* ps) {
|
||||
for (l = 0; l < size; l++) {
|
||||
if ((data & instruction->mask) == instruction->opcode) {
|
||||
j = 0;
|
||||
for (; instruction->operands[j] != 0 && j < 6; j++) {
|
||||
for (;j < 6 && instruction->operands[j] != 0; j++) {
|
||||
ppcps_field_t* field = &ps->operands[j];
|
||||
ps_operand_t* ps_operand = &ps_operands_array[instruction->operands[j]];
|
||||
|
||||
@ -195,4 +195,4 @@ void libps_snprint(char* str, int size, ut64 addr, ppcps_t* instr) {
|
||||
add += snprintf (str + add, bufsize - add, " cr%u", instr->operands[i].value);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user