added signal handler so that the directory can be cleaned up, while the daemon is running by sending SIGUSR1.