Created
December 2, 2016 11:17
-
-
Save tmr232/1bd64fbbbc07f2a7634bcb9275929dac to your computer and use it in GitHub Desktop.
Delete functions with multiple chunks in IDA
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import idaapi | |
import idautils | |
def iter_all_funcs(): | |
for func_ea in idautils.Functions(idaapi.cvar.inf.minEA, idaapi.cvar.inf.maxEA): | |
yield idaapi.get_func(func_ea) | |
def iter_multichunk_funcs(): | |
for func_t in iter_all_funcs(): | |
if func_t.tailqty > 0: | |
yield func_t | |
def delete_multichunk_funcs(): | |
for func_t in iter_multichunk_funcs(): | |
idaapi.del_func(func_t.startEA) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment