Restored original kill process functionality.

It appears this code, thought it doesn't work on Macs, may be more stable on Ubuntu. More research needed.