csv: fixed reading from buffered stream input - the last line/record in an input batch isn't read when available