fixed exit statements