ReactiveX/RxJavaString

Bug in StringObservable.split

firstone opened this issue · 1 comments

https://github.com/ReactiveX/RxJavaString/blob/1.x/src/main/java/rx/observables/StringObservable.java#L425

If running on Windows (with line separator consisting of 2 chars \r\n), sometimes leftover can include full line with \r but no \n. During the next call, this left over is added AFTER the splits are processed. The effect is having 2 lines with line break in the first element.

To fix it, it needs to prepend leftover PRIOR to doing split.

thanks for the bug report. a bunch of changes related to split this week.