Fix encoding of files