diff --git a/benchmarks/benches/utils.rs b/benchmarks/benches/utils.rs index b769bf2c7..f79d925e7 100644 --- a/benchmarks/benches/utils.rs +++ b/benchmarks/benches/utils.rs @@ -161,6 +161,7 @@ fn documents_from_jsonl(reader: impl Read) -> anyhow::Result> { while reader.read_line(&mut buf)? > 0 { documents.extend_from_json(&mut buf.as_bytes())?; + buf.clear(); } documents.finish()?;