Fixed the ptrace handler for signals such as SIGSEGV