closing files correctly in log2csv, debug for missing message types