mipsrop a bug in line 393
g3n3rous opened this issue · comments
G3n3rous commented
mipsrop code(line 391-392):
for xref in idautils.XrefsTo(idc.LocByName('system')):
ea = xref.frm
if ea >= start_ea and ea <= end_ea and idc.GetMnem(ea)[0] in ['j', 'b']:
in line 391,392, ea value might is Elf32_Sym addr of the function system, so index out of bound error occurred while executing idc.GetMnem(ea)[0]. I think we should judge idc.GetMnem(ea) return value whether is null.
add:
for xref in idautils.XrefsTo(idc.LocByName('system')):
ea = xref.frm
if ea >= start_ea and ea <= end_ea:
if idc.GetMnem(ea) != "" and idc.GetMnem(ea)[0] in ['j', 'b']: