From 0adbb8078be65a2c721084f8b45c314d86b4056a Mon Sep 17 00:00:00 2001 From: Nicolas Patry Date: Tue, 7 Jan 2025 17:06:30 +0100 Subject: [PATCH] What? --- src/api/tokio.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/api/tokio.rs b/src/api/tokio.rs index c0b0748..5a14620 100644 --- a/src/api/tokio.rs +++ b/src/api/tokio.rs @@ -670,6 +670,7 @@ impl ApiRepo { .await?; file.seek(SeekFrom::Start(length as u64)).await?; file.write_all(&committed.to_le_bytes()).await?; + file.flush().await; } } let mut f = tokio::fs::OpenOptions::new() @@ -722,6 +723,7 @@ impl ApiRepo { .await?; file.seek(SeekFrom::Start(start as u64)).await?; file.write_all(&buf).await?; + file.flush().await?; Ok((start, stop)) }