add function for catching signal handler on ROOT