changed exit to exit()