Fixing signal handler