Fix encoding of file content