bugfix: ChunkedDataReader handles zero-length chunk properly, add test