allowing to exit cleanly