More reliable Closing

Close the listener instead of just closing the file
Remove yoda trick
Fix Error string
Migrate sigCatch() to proper section of the code