Skip to content

Commit

Permalink
add destructor to ptrace_detach
Browse files Browse the repository at this point in the history
  • Loading branch information
n1nj4sec committed Apr 11, 2017
1 parent b84ae89 commit 7317374
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions memorpy/LinProcess.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,10 @@ def close(self):
if self.ptrace_started:
self.ptrace_detach()

def __del__(self):
if self.ptrace_started:
self.ptrace_detach()

def _open(self):
self.isProcessOpen = True
self.check_ptrace_scope()
Expand Down

0 comments on commit 7317374

Please sign in to comment.