Added code to catch bad command line arguments