corercted csvFile and exitcode handling