adds uncaught exception handler callback