encoding and decoding results in original file