XuQianJin-Stars commented on a change in pull request #6823: [FLINK-10134] UTF-16 support for TextInputFormat bug refixed URL: https://github.com/apache/flink/pull/6823#discussion_r226598262
########## File path: flink-core/src/main/java/org/apache/flink/api/common/io/DelimitedInputFormat.java ########## @@ -472,6 +498,7 @@ public void open(FileInputSplit split) throws IOException { this.offset = splitStart; if (this.splitStart != 0) { + setBomFileCharset(split); Review comment: `DelimitedInputFormat` is filled with a `readBuffer` variable when calling `fillBuffer(0)`. We can copy 4 bytes from readBuffer. It should not have a big impact. As follows: `System.arraycopy(this.readBuffer, 0, bomBuffer, 0, 4);` ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services