angusdev opened a new pull request #216: URL: https://github.com/apache/commons-csv/pull/216
Jira Issue: https://issues.apache.org/jira/browse/CSV-288 When checking if last token is delimiter in below line of code ```java // did we reach eof during the last iteration already ? EOF if (isEndOfFile(lastChar) || !isDelimiter(lastChar) && isEndOfFile(c)) { ``` `isDelimiter(lastChar)` unintentionally advance the buffer pointer and consume the first `"|"` when it comes to the `"b"` in `"a||b||c"` (lastChar is `"|"`, nextChar is also `"|"`, make it `"||"`). Subsequent read will see `"|c"` instead of `"||c"` so the second token is `"b|c"` To fix it, create a new indicator `isLastTokenDelimiter` instead of using `isDelimiter(lastChar)`, the indicator is set/reset in `isDelimiter()` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@commons.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org