def FindFuncEnd(ea):
"""
Determine a new function boundaries
@param ea: starting address of a new function
@return: if a function already exists, then return its end address.
If a function end cannot be determined, the return BADADDR
otherwise return the end address of the new function
"""
func = idaapi.func_t()
res = idaapi.find_func_bounds(ea, func, idaapi.FIND_FUNC_DEFINE)
if res == idaapi.FIND_FUNC_UNDEF:
return BADADDR
else:
return func.endEA
评论列表
文章目录