示例#1
0
文件: refs.py 项目: AmesianX/mcsema
def _is_ea_into_bad_code(ea, binary_is_pie):
  if not is_code(ea):
    return False

  import flow  # Circular dependency!
  term_inst, _ = flow.find_linear_terminator(ea)
  if not term_inst:
    return True

  succs = list(flow.get_static_successors(idc.BADADDR, term_inst, binary_is_pie))
  if not succs:
    return True

  for succ_ea in succs:
    if is_invalid_ea(succ_ea):
      return True

  return False
示例#2
0
def _is_ea_into_bad_code(ea, binary_is_pie):
  if not is_code(ea):
    return False

  import flow  # Circular dependency!
  term_inst = flow.find_linear_terminator(ea)
  if not term_inst:
    return True

  succs = list(flow.get_static_successors(idc.BADADDR, term_inst, binary_is_pie))
  if not succs:
    return True

  for succ_ea in succs:
    if is_invalid_ea(succ_ea):
      return True

  return False