Correct exit in shell with mac