Skip to content

Commit

Permalink
Merge pull request #31 from doronz88/feature/disable_xpc_transaction_…
Browse files Browse the repository at this point in the history
…exit

xpc: Add `disable_transaction_exit`
  • Loading branch information
doronz88 authored Jul 26, 2023
2 parents 1239bf1 + 3d54e77 commit fa6d619
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions hilda/snippets/xpc.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,15 @@ def from_xpc_object(address: int):
return lldb.hilda_client.from_ns(f'_CFXPCCreateCFObjectFromXPCObject({address})')


def disable_transaction_exit():
"""
xpc_transaction_exit_clean will kill the process when transaction is done.
By patching this function the process will stay alive.
"""
hilda = lldb.hilda_client
hilda.symbols.xpc_transaction_exit_clean.poke_text('ret')


def to_xpc_object(obj: object):
"""
Convert python object to XPC object.
Expand Down

0 comments on commit fa6d619

Please sign in to comment.