lldb script

(lldb) command script add test
Enter your Python command(s). Type 'DONE' to end.
You must define a Python function with this signature:
def my_command_impl(debugger, args, result, internal_dict):
    ReturnObject = lldb.SBCommandReturnObject()
    while True:
        debugger.GetCommandInterpreter().HandleCommand('p *(char*)($rbp-0x331)', ReturnObject)
        ret = ReturnObject.GetOutput()
        print(ret);
        if ret.find("ff") > 0:
            debugger.HandleCommand('dis')
            break
        debugger.GetCommandInterpreter().HandleCommand('ni', ReturnObject)

你可能感兴趣的:(lldb script)