Change the return type of exitImmediately