Exit using the proper exit code.