handle SIGTERM
rename signal handler for term and hup
Merge pull request #51 from luksen/master

Handle SIGTERM