removing explicit exit calls